Commit 00c0e85f authored by sebastian's avatar sebastian

ZP-558 #comment fixed wrong folderid length

git-svn-id: https://z-push.org/svn/z-push/trunk@1964 b7dd7b3b-3a3c-0410-9da9-bee62a6cc5b5
parent 7013c516
...@@ -235,17 +235,17 @@ class ZPushAdminCLI { ...@@ -235,17 +235,17 @@ class ZPushAdminCLI {
elseif (isset($options['type']) && !empty($options['type'])) elseif (isset($options['type']) && !empty($options['type']))
self::$type = strtolower(trim($options['type'])); self::$type = strtolower(trim($options['type']));
// if type is set, it must be one of known types or a 48 byte long folder id // if type is set, it must be one of known types or a 44 byte long folder id
if (self::$type !== false) { if (self::$type !== false) {
if (self::$type !== self::TYPE_OPTION_EMAIL && if (self::$type !== self::TYPE_OPTION_EMAIL &&
self::$type !== self::TYPE_OPTION_CALENDAR && self::$type !== self::TYPE_OPTION_CALENDAR &&
self::$type !== self::TYPE_OPTION_CONTACT && self::$type !== self::TYPE_OPTION_CONTACT &&
self::$type !== self::TYPE_OPTION_TASK && self::$type !== self::TYPE_OPTION_TASK &&
self::$type !== self::TYPE_OPTION_NOTE && self::$type !== self::TYPE_OPTION_NOTE &&
strlen(self::$type) !== 48) { strlen(self::$type) !== 44) {
self::$errormessage = "Wrong 'type'. Possible values are: ". self::$errormessage = "Wrong 'type'. Possible values are: ".
"'".self::TYPE_OPTION_EMAIL."', '".self::TYPE_OPTION_CALENDAR."', '".self::TYPE_OPTION_CONTACT."', '".self::TYPE_OPTION_TASK."', '".self::TYPE_OPTION_NOTE."' ". "'".self::TYPE_OPTION_EMAIL."', '".self::TYPE_OPTION_CALENDAR."', '".self::TYPE_OPTION_CONTACT."', '".self::TYPE_OPTION_TASK."', '".self::TYPE_OPTION_NOTE."' ".
"or a 48 byte long folder id."; "or a 44 byte long folder id (as hex).";
return; return;
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment