Author: chabotc
Date: Tue Jun 17 09:42:51 2008
New Revision: 668736

URL: http://svn.apache.org/viewvc?rev=668736&view=rev
Log:
2 small fixes for basic sample activities support in rest api

Modified:
    
incubator/shindig/trunk/php/src/socialrest/samplecontainer/BasicActivitiesService.php
    
incubator/shindig/trunk/php/src/socialrest/samplecontainer/XmlStateFileFetcher.php

Modified: 
incubator/shindig/trunk/php/src/socialrest/samplecontainer/BasicActivitiesService.php
URL: 
http://svn.apache.org/viewvc/incubator/shindig/trunk/php/src/socialrest/samplecontainer/BasicActivitiesService.php?rev=668736&r1=668735&r2=668736&view=diff
==============================================================================
--- 
incubator/shindig/trunk/php/src/socialrest/samplecontainer/BasicActivitiesService.php
 (original)
+++ 
incubator/shindig/trunk/php/src/socialrest/samplecontainer/BasicActivitiesService.php
 Tue Jun 17 09:42:51 2008
@@ -65,9 +65,7 @@
        public function createActivity(UserId $userId, $activity, SecurityToken 
$token)
        {
                // TODO: Validate the activity and do any template expanding
-               $activity->setUserId($userId->getUserId($token));
-               $activity->setPostedTime(time());
-               
XmlStateFileFetcher::get()->createActivity($userId->getUserId($token), 
$activity);
+               
XmlStateFileFetcher::get()->createActivity($userId->getUserId($token), 
$activity, $token->getAppId());
                return new ResponseItem(null, null, array());
        }
 }

Modified: 
incubator/shindig/trunk/php/src/socialrest/samplecontainer/XmlStateFileFetcher.php
URL: 
http://svn.apache.org/viewvc/incubator/shindig/trunk/php/src/socialrest/samplecontainer/XmlStateFileFetcher.php?rev=668736&r1=668735&r2=668736&view=diff
==============================================================================
--- 
incubator/shindig/trunk/php/src/socialrest/samplecontainer/XmlStateFileFetcher.php
 (original)
+++ 
incubator/shindig/trunk/php/src/socialrest/samplecontainer/XmlStateFileFetcher.php
 Tue Jun 17 09:42:51 2008
@@ -247,7 +247,7 @@
                        $activity->setTitle($this->turnEvil($title));
                        $activity->setBody($this->turnEvil($body));
                        
$activity->setMediaItems($this->getMediaItems($activityItem));
-                       $this->createActivity($userId, $activity);
+                       $this->createActivity($userId, $activity, 0);
                }
        }
        
@@ -263,9 +263,8 @@
                return $media;
        }
        
-       public function createActivity($userId, $activity)
+       public function createActivity($userId, $activity, $appId)
        {
-               
                if ($this->allActivities == null && 
!is_array($this->allActivities)) {
                        $this->setupActivities();
                }


Reply via email to