Commit 99abc224 authored by Fabián Rodríguez's avatar Fabián Rodríguez

remove unused methods

parent 232539cd
......@@ -167,12 +167,6 @@ class Person < ActiveRecord::Base
}.call
end
def self.public_search(query, opts={})
return [] if query.to_s.blank? || query.to_s.length < 3
sql, tokens = self.search_query_string(query)
Person.searchable.where(sql, *tokens)
end
def name(opts = {})
if self.profile.nil?
fix_profile
......
......@@ -128,10 +128,6 @@ class Photo < ActiveRecord::Base
}
end
def thumb_hash
{:thumb_url => url(:thumb_medium), :id => id, :album_id => nil}
end
def queue_processing_job
Resque.enqueue(Jobs::ProcessPhoto, self.id)
end
......
......@@ -103,11 +103,6 @@ class Post < ActiveRecord::Base
reshares.where(:author_id => user.person.id).first
end
def participation_for(user)
return unless user
participations.where(:author_id => user.person.id).first
end
def like_for(user)
return unless user
likes.where(:author_id => user.person.id).first
......@@ -133,10 +128,6 @@ class Post < ActiveRecord::Base
false
end
def triggers_caching?
true
end
def comment_email_subject
I18n.t('notifier.a_post_you_shared')
end
......
......@@ -165,17 +165,6 @@ class User < ActiveRecord::Base
self.hidden_shareables[share_type].present?
end
def self.create_from_invitation!(invitation)
user = User.new
user.generate_keys
user.send(:generate_invitation_token)
user.email = invitation.identifier if invitation.service == 'email'
# we need to make a custom validator here to make this safer
user.save(:validate => false)
user
end
def send_reset_password_instructions
generate_reset_password_token! if should_generate_reset_token?
Resque.enqueue(Jobs::ResetPassword, self.id)
......
......@@ -50,11 +50,6 @@ class Stream::Base
includes(:profile)
end
# @return [String]
def contacts_link_title
I18n.translate('aspects.selected_contacts.view_all_contacts')
end
# @return [String] def contacts_title 'change me in lib/base_stream.rb!'
def contacts_title
'change me in lib/base_stream.rb!'
......
......@@ -31,11 +31,4 @@ class User
p
end
end
def post_at_time(time)
to_aspect = self.aspects.length == 1 ? self.aspects.first : self.aspects.where(:name => "generic")
p = self.post(:status_message, :text => 'hi', :to => to_aspect)
p.created_at = time
p.save!
end
end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment