]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - actions/foaf.php
Merge branch 'master' of gitorious.org:statusnet/mainline into testing
[quix0rs-gnu-social.git] / actions / foaf.php
index fc56e19b4f5c4dbb37a37e4e7a9e1262fefcdbe9..2f054de0c9f73885fafbb49e00e7808ca2cd9e29 100644 (file)
@@ -95,7 +95,9 @@ class FoafAction extends Action
         // Would be nice to tell if they were a Person or not (e.g. a #person usertag?)
         $this->elementStart('Agent', array('rdf:about' =>
                                              $this->user->uri));
-        $this->element('mbox_sha1sum', null, sha1('mailto:' . $this->user->email));
+        if ($this->user->email) {
+            $this->element('mbox_sha1sum', null, sha1('mailto:' . $this->user->email));
+        }
         if ($this->profile->fullname) {
             $this->element('name', null, $this->profile->fullname);
         }
@@ -126,7 +128,7 @@ class FoafAction extends Action
                 $this->element('geo:lat', null, $location->lat);
             }
             if ($location->lon) {
-                $this->element('geo:long', null, $location->lat);
+                $this->element('geo:long', null, $location->lon);
             }
             if ($location->getURL()) {
                 $this->element('page', array('rdf:resource'=>$location->getURL()));