Module: Shared::IsData::Pinnable

Extended by:
ActiveSupport::Concern
Defined in:
app/models/concerns/shared/is_data/pinnable.rb

Overview

Shared code for…

Instance Method Summary (collapse)

Instance Method Details

- (Boolean) pinned?(user)

Returns:

  • (Boolean)


11
12
13
# File 'app/models/concerns/shared/is_data/pinnable.rb', line 11

def pinned?(user)
  user.pinboard_items.for_object(self.metamorphosize).count > 0
end