]> git.openstreetmap.org Git - rails.git/blobdiff - app/controllers/friendships_controller.rb
Modify the way Friends are added
[rails.git] / app / controllers / friendships_controller.rb
index 8f0c1ad859c4332eb46c81d82db4e28d6a8fe755..8de438fd21fda3d76c12851f8854ed35be345a3d 100644 (file)
@@ -18,7 +18,7 @@ class FriendshipsController < ApplicationController
       friendship.befriender = current_user
       friendship.befriendee = @friend
       if current_user.friends_with?(@friend)
-        flash[:warning] = t ".already_a_friend", :name => @friend.display_name
+        flash[:warning] = t ".already_followed", :name => @friend.display_name
       elsif current_user.friendships.where(:created_at => Time.now.utc - 1.hour..).count >= current_user.max_friends_per_hour
         flash[:error] = t ".limit_exceeded"
       elsif friendship.save
@@ -40,7 +40,7 @@ class FriendshipsController < ApplicationController
         Friendship.where(:befriender => current_user, :befriendee => @friend).delete_all
         flash[:notice] = t ".success", :name => @friend.display_name
       else
-        flash[:error] = t ".not_a_friend", :name => @friend.display_name
+        flash[:error] = t ".not_followed", :name => @friend.display_name
       end
 
       referer = safe_referer(params[:referer]) if params[:referer]