posting empty albums to people

This commit is contained in:
ilya 2010-08-24 16:05:29 -07:00
parent c0dc2c5047
commit f5ae090e9b
2 changed files with 4 additions and 1 deletions

View file

@ -58,7 +58,7 @@ def warzombie
def set_profile_photo
render :nothing => true
album = current_user.post(:album, :name => "Profile Photos")
album = current_user.post( :album, :to => current_user.all_group_ids, :name => "Profile Photos")
backer_number = YAML.load_file(Rails.root.join('config','backer_number.yml'))[:seed_number].to_i
username = backer_info[backer_number]['username'].gsub(/ /,'').downcase

View file

@ -229,6 +229,9 @@ class User
self.person.save!
end
def all_group_ids
self.groups.all.map{|x| x.id}
end
protected
def generate_key
OpenSSL::PKey::RSA::generate 1024