]> git.mxchange.org Git - friendica.git/blobdiff - src/Model/Event.php
codeblock updates
[friendica.git] / src / Model / Event.php
index 576f47ba832d6fa95b94beea42cf798fefe78af8..3ce86017ba99028203aeb946a09c1a70bbe530cb 100644 (file)
@@ -48,8 +48,10 @@ class Event extends BaseObject
                }
 
                if ($simple) {
+                       $o = '';
+
                        if (!empty($event['summary'])) {
-                               $o = "<h3>" . BBCode::convert(Strings::escapeHtml($event['summary']), false, $simple) . "</h3>";
+                               $o .= "<h3>" . BBCode::convert(Strings::escapeHtml($event['summary']), false, $simple) . "</h3>";
                        }
 
                        if (!empty($event['desc'])) {
@@ -642,15 +644,17 @@ class Event extends BaseObject
         */
        private static function formatListForExport(array $events, $format)
        {
+               $o = '';
+
                if (!count($events)) {
-                       return '';
+                       return $o;
                }
 
                switch ($format) {
                        // Format the exported data as a CSV file.
                        case "csv":
                                header("Content-type: text/csv");
-                               $o = '"Subject", "Start Date", "Start Time", "Description", "End Date", "End Time", "Location"' . PHP_EOL;
+                               $o .= '"Subject", "Start Date", "Start Time", "Description", "End Date", "End Time", "Location"' . PHP_EOL;
 
                                foreach ($events as $event) {
                                        /// @todo The time / date entries don't include any information about the