ssafronova (ssafronova) wrote in changelog,
ssafronova
ssafronova
changelog

[ljcom] r9384: LJSUP-6568: Disable useless settings for...

Committer: ssafronova
LJSUP-6568: Disable useless settings for FB-users
U   trunk/cgi-bin/LJ/Hooks/ESN.pm
Modified: trunk/cgi-bin/LJ/Hooks/ESN.pm
===================================================================
--- trunk/cgi-bin/LJ/Hooks/ESN.pm	2010-08-24 09:15:39 UTC (rev 9383)
+++ trunk/cgi-bin/LJ/Hooks/ESN.pm	2010-08-24 09:34:07 UTC (rev 9384)
@@ -167,17 +167,35 @@
 });
 
 LJ::register_hook('esn_settings_my_account', sub {
-    [
-        'SupOfficialPost',
-        'OfficialPost',
-        'JournalNewComment-u',
-        'CommunityEntryReply',
-        'CommentReply',
-        'PollVote-u',
-        'Befriended-u',
-        'Defriended-u',
-        'UserMessageRecvd-u',
-    ];
+
+    my $remote = LJ::get_remote();
+
+    if ($remote->is_identity) {
+
+        return [
+            'SupOfficialPost',
+            'OfficialPost',
+            'CommentReply',
+            'PollVote-u',
+            'Befriended-u',
+            'Defriended-u',
+            'UserMessageRecvd-u',
+        ];
+
+    } else {
+
+        return [
+            'SupOfficialPost',
+            'OfficialPost',
+            'JournalNewComment-u',
+            'CommunityEntryReply',
+            'CommentReply',
+            'PollVote-u',
+            'Befriended-u',
+            'Defriended-u',
+            'UserMessageRecvd-u',
+         ];
+    }
 });
 
 LJ::register_hook('esn_quota_error', sub {

Tags: ljcom, pm, ssafronova
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments