alf (red_alf) wrote in changelog,
alf
red_alf
changelog

[livejournal] r23366: LJSUP-10900: Implement MessagePack proto...

Committer: afedorov
LJSUP-10900: Implement MessagePack protocol driver to access to Relation Service.

U   trunk/cgi-bin/ljrelation.pl
Modified: trunk/cgi-bin/ljrelation.pl
===================================================================
--- trunk/cgi-bin/ljrelation.pl	2012-11-27 03:28:41 UTC (rev 23365)
+++ trunk/cgi-bin/ljrelation.pl	2012-11-27 03:47:32 UTC (rev 23366)
@@ -269,7 +269,12 @@
     my ($userid, $targetid, $type) = @_;
     return undef unless $type && $userid && $targetid;
 
-    my $result = LJ::RelationService->is_relation_to($userid, $targetid, $type);
+    my $result;
+    if ( ref $type eq 'ARRAY' ) {
+        $result = LJ::RelationService->is_relation_type_to($userid, $targetid, $type);
+    } else {
+        $result = LJ::RelationService->is_relation_to($userid, $targetid, $type);
+    }
     return $result;
 }
 

Tags: afedorov, livejournal, pl, red_alf
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