From: Georg Ehrke Date: Tue, 26 Jun 2012 13:20:29 +0000 (+0200) Subject: add OC_Calendar_Object::createUID() X-Git-Tag: v4.5.0beta1~74^2~49^2~161^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=b9ce4e1f406f1ee57d58b409c368a89aa9ddde9a;p=nextcloud-server.git add OC_Calendar_Object::createUID() --- diff --git a/apps/calendar/lib/object.php b/apps/calendar/lib/object.php index 7f3322b1ab5..0531a56fc50 100644 --- a/apps/calendar/lib/object.php +++ b/apps/calendar/lib/object.php @@ -216,6 +216,14 @@ class OC_Calendar_Object{ return true; } + + /** + * @brief Creates a UID + * @return string + */ + protected static function createUID(){ + return substr(md5(rand().time()),0,10); + } /** * @brief Extracts data from a vObject-Object