[Pkg-owncloud-commits] [php-sabre-vobject] 24/341: Update to PHP5.4 and format code…
David Prévot
taffit at moszumanska.debian.org
Tue Aug 11 13:35:28 UTC 2015
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository php-sabre-vobject.
commit 447385d93b9f325b9744b6f64677cbdb9605c0fc
Author: Ivan Enderlin <ivan.enderlin at hoa-project.net>
Date: Thu Nov 13 11:11:14 2014 +0100
Update to PHP5.4 and format code…
… it means:
* remove `array()` and use the short-syntax instead,
* align some operators for consistencies,
* remove some useless `else` branch.
---
bin/generate_vcards | 4 +-
bin/vobject | 4 +-
lib/Cli.php | 2 +-
lib/ITip/Broker.php | 122 +++++++++++++--------------
lib/Parser/Json.php | 6 +-
lib/Parser/MimeDir.php | 20 ++---
lib/Property/Binary.php | 2 +-
lib/Property/Float.php | 5 +-
lib/Property/Integer.php | 2 +-
lib/Property/Text.php | 25 +++---
lib/Property/VCard/DateAndOrTime.php | 4 +-
lib/timezonedata/exchangezones.php | 158 +++++++++++++++++------------------
lib/timezonedata/lotuszones.php | 4 +-
lib/timezonedata/php-bc.php | 4 +-
lib/timezonedata/php-workaround.php | 4 +-
15 files changed, 182 insertions(+), 184 deletions(-)
diff --git a/bin/generate_vcards b/bin/generate_vcards
index 6520359..f7a1695 100755
--- a/bin/generate_vcards
+++ b/bin/generate_vcards
@@ -5,10 +5,10 @@ namespace Sabre\VObject;
// This sucks.. we have to try to find the composer autoloader. But chances
// are, we can't find it this way. So we'll do our bestest
-$paths = array(
+$paths = [
__DIR__ . '/../vendor/autoload.php', // In case vobject is cloned directly
__DIR__ . '/../../../autoload.php', // In case vobject is a composer dependency.
-);
+];
foreach($paths as $path) {
if (file_exists($path)) {
diff --git a/bin/vobject b/bin/vobject
index e52b4fb..2aca7e7 100755
--- a/bin/vobject
+++ b/bin/vobject
@@ -5,10 +5,10 @@ namespace Sabre\VObject;
// This sucks.. we have to try to find the composer autoloader. But chances
// are, we can't find it this way. So we'll do our bestest
-$paths = array(
+$paths = [
__DIR__ . '/../vendor/autoload.php', // In case vobject is cloned directly
__DIR__ . '/../../../autoload.php', // In case vobject is a composer dependency.
-);
+];
foreach($paths as $path) {
if (file_exists($path)) {
diff --git a/lib/Cli.php b/lib/Cli.php
index 81bc96e..9561080 100644
--- a/lib/Cli.php
+++ b/lib/Cli.php
@@ -217,7 +217,7 @@ class Cli {
throw new InvalidArgumentException('Too many arguments');
}
- if (!in_array($positional[0], array('validate','repair','convert','color'))) {
+ if (!in_array($positional[0], ['validate','repair','convert','color'])) {
throw new InvalidArgumentException('Uknown command: ' . $positional[0]);
}
diff --git a/lib/ITip/Broker.php b/lib/ITip/Broker.php
index 778f5e4..8bda481 100644
--- a/lib/ITip/Broker.php
+++ b/lib/ITip/Broker.php
@@ -66,7 +66,7 @@ class Broker {
*
* @var string[]
*/
- public $significantChangeProperties = array(
+ public $significantChangeProperties = [
'DTSTART',
'DTEND',
'DURATION',
@@ -75,7 +75,7 @@ class Broker {
'RDATE',
'EXDATE',
'STATUS',
- );
+ ];
/**
* This method is used to process an incoming itip message.
@@ -172,16 +172,16 @@ class Broker {
}
if (!isset($oldCalendar->VEVENT)) {
// We only support events at the moment
- return array();
+ return [];
}
$oldEventInfo = $this->parseEventInfo($oldCalendar);
} else {
- $oldEventInfo = array(
+ $oldEventInfo = [
'organizer' => null,
'significantChangeHash' => '',
- 'attendees' => array(),
- );
+ 'attendees' => [],
+ ];
}
$userHref = (array)$userHref;
@@ -193,17 +193,17 @@ class Broker {
}
if (!isset($calendar->VEVENT)) {
// We only support events at the moment
- return array();
+ return [];
}
$eventInfo = $this->parseEventInfo($calendar);
if (!$eventInfo['attendees'] && !$oldEventInfo['attendees']) {
// If there were no attendees on either side of the equation,
// we don't need to do anything.
- return array();
+ return [];
}
if (!$eventInfo['organizer'] && !$oldEventInfo['organizer']) {
// There was no organizer before or after the change.
- return array();
+ return [];
}
$baseCalendar = $calendar;
@@ -221,14 +221,14 @@ class Broker {
// cancellation / decline.
if (!$oldCalendar) {
// No old and no new calendar, there's no thing to do.
- return array();
+ return [];
}
$eventInfo = $oldEventInfo;
if (in_array($eventInfo['organizer'], $userHref)) {
// This is an organizer deleting the event.
- $eventInfo['attendees'] = array();
+ $eventInfo['attendees'] = [];
// Increasing the sequence, but only if the organizer deleted
// the event.
$eventInfo['sequence']++;
@@ -236,9 +236,9 @@ class Broker {
// This is an attendee deleting the event.
foreach($eventInfo['attendees'] as $key=>$attendee) {
if (in_array($attendee['href'], $userHref)) {
- $eventInfo['attendees'][$key]['instances'] = array('master' =>
- array('id'=>'master', 'partstat' => 'DECLINED')
- );
+ $eventInfo['attendees'][$key]['instances'] = ['master' =>
+ ['id'=>'master', 'partstat' => 'DECLINED']
+ ];
}
}
}
@@ -258,7 +258,7 @@ class Broker {
}
}
}
- return array();
+ return [];
}
@@ -340,7 +340,7 @@ class Broker {
if (!$existingObject) {
return null;
}
- $instances = array();
+ $instances = [];
$requestStatus = '2.0;Success';
// Finding all the instances the attendee replied to.
@@ -379,9 +379,9 @@ class Broker {
if (!$attendeeFound) {
// Adding a new attendee. The iTip documentation calls this
// a party crasher.
- $attendee = $vevent->add('ATTENDEE', $itipMessage->sender, array(
+ $attendee = $vevent->add('ATTENDEE', $itipMessage->sender, [
'PARTSTAT' => $instances[$recurId]
- ));
+ ]);
if ($itipMessage->senderName) $attendee['CN'] = $itipMessage->senderName;
}
unset($instances[$recurId]);
@@ -431,9 +431,9 @@ class Broker {
}
if (!$attendeeFound) {
// Adding a new attendee
- $attendee = $newObject->add('ATTENDEE', $itipMessage->sender, array(
+ $attendee = $newObject->add('ATTENDEE', $itipMessage->sender, [
'PARTSTAT' => $partstat
- ));
+ ]);
if ($itipMessage->senderName) {
$attendee['CN'] = $itipMessage->senderName;
}
@@ -461,15 +461,15 @@ class Broker {
protected function parseEventForOrganizer(VCalendar $calendar, array $eventInfo, array $oldEventInfo) {
// Merging attendee lists.
- $attendees = array();
+ $attendees = [];
foreach($oldEventInfo['attendees'] as $attendee) {
- $attendees[$attendee['href']] = array(
+ $attendees[$attendee['href']] = [
'href' => $attendee['href'],
'oldInstances' => $attendee['instances'],
- 'newInstances' => array(),
+ 'newInstances' => [],
'name' => $attendee['name'],
'forceSend' => null,
- );
+ ];
}
foreach($eventInfo['attendees'] as $attendee) {
if (isset($attendees[$attendee['href']])) {
@@ -477,17 +477,17 @@ class Broker {
$attendees[$attendee['href']]['newInstances'] = $attendee['instances'];
$attendees[$attendee['href']]['forceSend'] = $attendee['forceSend'];
} else {
- $attendees[$attendee['href']] = array(
+ $attendees[$attendee['href']] = [
'href' => $attendee['href'],
- 'oldInstances' => array(),
+ 'oldInstances' => [],
'newInstances' => $attendee['instances'],
'name' => $attendee['name'],
'forceSend' => $attendee['forceSend'],
- );
+ ];
}
}
- $messages = array();
+ $messages = [];
foreach($attendees as $attendee) {
@@ -516,19 +516,19 @@ class Broker {
// Creating the new iCalendar body.
$icalMsg = new VCalendar();
$icalMsg->METHOD = $message->method;
- $event = $icalMsg->add('VEVENT', array(
+ $event = $icalMsg->add('VEVENT', [
'UID' => $message->uid,
'SEQUENCE' => $message->sequence,
- ));
+ ]);
if (isset($calendar->VEVENT->SUMMARY)) {
$event->add('SUMMARY', $calendar->VEVENT->SUMMARY->getValue());
}
$event->add(clone $calendar->VEVENT->DTSTART);
$org = $event->add('ORGANIZER', $eventInfo['organizer']);
if ($eventInfo['organizerName']) $org['CN'] = $eventInfo['organizerName'];
- $event->add('ATTENDEE', $attendee['href'], array(
+ $event->add('ATTENDEE', $attendee['href'], [
'CN' => $attendee['name'],
- ));
+ ]);
$message->significantChange = true;
} else {
@@ -564,7 +564,7 @@ class Broker {
// We need to find a list of events that the attendee
// is not a part of to add to the list of exceptions.
- $exceptions = array();
+ $exceptions = [];
foreach($eventInfo['instances'] as $instanceId=>$vevent) {
if (!isset($attendee['newInstances'][$instanceId])) {
$exceptions[] = $instanceId;
@@ -632,23 +632,23 @@ class Broker {
protected function parseEventForAttendee(VCalendar $calendar, array $eventInfo, array $oldEventInfo, $attendee) {
if ($this->scheduleAgentServerRules && $eventInfo['organizerScheduleAgent']==='CLIENT') {
- return array();
+ return [];
}
// Don't bother generating messages for events that have already been
// cancelled.
if ($eventInfo['status']==='CANCELLED') {
- return array();
+ return [];
}
- $instances = array();
+ $instances = [];
foreach($oldEventInfo['attendees'][$attendee]['instances'] as $instance) {
- $instances[$instance['id']] = array(
+ $instances[$instance['id']] = [
'id' => $instance['id'],
'oldstatus' => $instance['partstat'],
'newstatus' => null,
- );
+ ];
}
foreach($eventInfo['attendees'][$attendee]['instances'] as $instance) {
@@ -656,11 +656,11 @@ class Broker {
if (isset($instances[$instance['id']])) {
$instances[$instance['id']]['newstatus'] = $instance['partstat'];
} else {
- $instances[$instance['id']] = array(
+ $instances[$instance['id']] = [
'id' => $instance['id'],
'oldstatus' => null,
'newstatus' => $instance['partstat'],
- );
+ ];
}
}
@@ -677,11 +677,11 @@ class Broker {
if (isset($instances[$exDate])) {
$instances[$exDate]['newstatus'] = 'DECLINED';
} else {
- $instances[$exDate] = array(
+ $instances[$exDate] = [
'id' => $exDate,
'oldstatus' => null,
'newstatus' => 'DECLINED',
- );
+ ];
}
}
@@ -721,10 +721,10 @@ class Broker {
continue;
}
- $event = $icalMsg->add('VEVENT', array(
+ $event = $icalMsg->add('VEVENT', [
'UID' => $message->uid,
'SEQUENCE' => $message->sequence,
- ));
+ ]);
$summary = isset($calendar->VEVENT->SUMMARY)?$calendar->VEVENT->SUMMARY->getValue():'';
// Adding properties from the correct source instance
if (isset($eventInfo['instances'][$instance['id']])) {
@@ -739,7 +739,7 @@ class Broker {
$dt = DateTimeParser::parse($instance['id'], $eventInfo['timezone']);
// Treat is as a DATE field
if (strlen($instance['id']) <= 8) {
- $event->add('DTSTART', $dt, array('VALUE' => 'DATE'));
+ $event->add('DTSTART', $dt, ['VALUE' => 'DATE']);
} else {
$event->add('DTSTART', $dt);
}
@@ -751,7 +751,7 @@ class Broker {
$dt = DateTimeParser::parse($instance['id'], $eventInfo['timezone']);
// Treat is as a DATE field
if (strlen($instance['id']) <= 8) {
- $event->add('RECURRENCE-ID', $dt, array('VALUE' => 'DATE'));
+ $event->add('RECURRENCE-ID', $dt, ['VALUE' => 'DATE']);
} else {
$event->add('RECURRENCE-ID', $dt);
}
@@ -760,9 +760,9 @@ class Broker {
if ($message->recipientName) {
$organizer['CN'] = $message->recipientName;
}
- $attendee = $event->add('ATTENDEE', $message->sender, array(
+ $attendee = $event->add('ATTENDEE', $message->sender, [
'PARTSTAT' => $instance['newstatus']
- ));
+ ]);
if ($message->senderName) {
$attendee['CN'] = $message->senderName;
}
@@ -772,9 +772,9 @@ class Broker {
if ($hasReply) {
$message->message = $icalMsg;
- return array($message);
+ return [$message];
} else {
- return array();
+ return [];
}
}
@@ -809,10 +809,10 @@ class Broker {
// Now we need to collect a list of attendees, and which instances they
// are a part of.
- $attendees = array();
+ $attendees = [];
- $instances = array();
- $exdate = array();
+ $instances = [];
+ $exdate = [];
foreach($calendar->VEVENT as $vevent) {
@@ -881,23 +881,23 @@ class Broker {
if (isset($attendees[$attendee->getNormalizedValue()])) {
- $attendees[$attendee->getNormalizedValue()]['instances'][$recurId] = array(
+ $attendees[$attendee->getNormalizedValue()]['instances'][$recurId] = [
'id' => $recurId,
'partstat' => $partStat,
'force-send' => $forceSend,
- );
+ ];
} else {
- $attendees[$attendee->getNormalizedValue()] = array(
+ $attendees[$attendee->getNormalizedValue()] = [
'href' => $attendee->getNormalizedValue(),
- 'instances' => array(
- $recurId => array(
+ 'instances' => [
+ $recurId => [
'id' => $recurId,
'partstat' => $partStat,
- ),
- ),
+ ],
+ ],
'name' => isset($attendee['CN'])?(string)$attendee['CN']:null,
'forceSend' => $forceSend,
- );
+ ];
}
}
diff --git a/lib/Parser/Json.php b/lib/Parser/Json.php
index 46acec8..0555013 100644
--- a/lib/Parser/Json.php
+++ b/lib/Parser/Json.php
@@ -60,10 +60,10 @@ class Json extends Parser {
switch($this->input[0]) {
case 'vcalendar' :
- $this->root = new VCalendar(array(), false);
+ $this->root = new VCalendar([], false);
break;
case 'vcard' :
- $this->root = new VCard(array(), false);
+ $this->root = new VCard([], false);
break;
default :
throw new ParseException('The root component must either be a vcalendar, or a vcard');
@@ -110,7 +110,7 @@ class Json extends Parser {
$jComp[2]
);
- } else $components = array();
+ } else $components = [];
return $this->root->createComponent(
$jComp[0],
diff --git a/lib/Parser/MimeDir.php b/lib/Parser/MimeDir.php
index 216da46..d424f74 100644
--- a/lib/Parser/MimeDir.php
+++ b/lib/Parser/MimeDir.php
@@ -112,7 +112,7 @@ class MimeDir extends Parser {
throw new ParseException('This parser only supports VCARD and VCALENDAR files');
}
- $this->root = new $class(array(), false);
+ $this->root = new $class([], false);
while(true) {
@@ -147,7 +147,7 @@ class MimeDir extends Parser {
// Start of a new component
if (strtoupper(substr($line, 0, 6)) === 'BEGIN:') {
- $component = $this->root->createComponent(substr($line,6), array(), false);
+ $component = $this->root->createComponent(substr($line,6), [], false);
while(true) {
@@ -302,11 +302,11 @@ class MimeDir extends Parser {
//echo $regex, "\n"; die();
preg_match_all($regex, $line, $matches, PREG_SET_ORDER);
- $property = array(
+ $property = [
'name' => null,
- 'parameters' => array(),
+ 'parameters' => [],
'value' => null
- );
+ ];
$lastParam = null;
@@ -333,10 +333,10 @@ class MimeDir extends Parser {
} elseif (is_array($property['parameters'][$lastParam])) {
$property['parameters'][$lastParam][] = $value;
} else {
- $property['parameters'][$lastParam] = array(
+ $property['parameters'][$lastParam] = [
$property['parameters'][$lastParam],
$value
- );
+ ];
}
continue;
}
@@ -377,8 +377,8 @@ class MimeDir extends Parser {
//
// Our parser will get those as parameters without a value instead, so
// we're filtering these parameters out first.
- $namedParameters = array();
- $namelessParameters = array();
+ $namedParameters = [];
+ $namelessParameters = [];
foreach($property['parameters'] as $name=>$value) {
if (!is_null($value)) {
@@ -475,7 +475,7 @@ class MimeDir extends Parser {
$matches = preg_split($regex, $input, -1, PREG_SPLIT_DELIM_CAPTURE | PREG_SPLIT_NO_EMPTY);
- $resultArray = array();
+ $resultArray = [];
$result = '';
foreach($matches as $match) {
diff --git a/lib/Property/Binary.php b/lib/Property/Binary.php
index 9ca1bef..85d2a24 100644
--- a/lib/Property/Binary.php
+++ b/lib/Property/Binary.php
@@ -103,7 +103,7 @@ class Binary extends Property {
*/
public function getJsonValue() {
- return array(base64_encode($this->getValue()));
+ return [base64_encode($this->getValue())];
}
diff --git a/lib/Property/Float.php b/lib/Property/Float.php
index 5b1f17e..e53f178 100644
--- a/lib/Property/Float.php
+++ b/lib/Property/Float.php
@@ -95,10 +95,9 @@ class Float extends Property {
// See:
// http://tools.ietf.org/html/draft-ietf-jcardcal-jcal-04#section-3.4.1.2
if ($this->name==='GEO') {
- return array($val);
- } else {
- return $val;
+ return [$val];
}
+ return $val;
}
}
diff --git a/lib/Property/Integer.php b/lib/Property/Integer.php
index fbcee70..ef1c57e 100644
--- a/lib/Property/Integer.php
+++ b/lib/Property/Integer.php
@@ -66,7 +66,7 @@ class Integer extends Property {
*/
public function getJsonValue() {
- return array((int)$this->getValue());
+ return [(int)$this->getValue()];
}
}
diff --git a/lib/Property/Text.php b/lib/Property/Text.php
index 3cfa84f..e4b75a0 100644
--- a/lib/Property/Text.php
+++ b/lib/Property/Text.php
@@ -32,7 +32,7 @@ class Text extends Property {
*
* @var array
*/
- protected $structuredValues = array(
+ protected $structuredValues = [
// vCard
'N',
'ADR',
@@ -41,7 +41,7 @@ class Text extends Property {
// iCalendar
'REQUEST-STATUS',
- );
+ ];
/**
* Some text components have a minimum number of components.
@@ -51,10 +51,10 @@ class Text extends Property {
*
* @var array
*/
- protected $minimumPropertyValues = array(
+ protected $minimumPropertyValues = [
'N' => 5,
'ADR' => 7,
- );
+ ];
/**
* Creates the property.
@@ -70,7 +70,7 @@ class Text extends Property {
* @param string $group The vcard property group
* @return void
*/
- public function __construct(Component $root, $name, $value = null, array $parameters = array(), $group = null) {
+ public function __construct(Component $root, $name, $value = null, array $parameters = [], $group = null) {
// There's two types of multi-valued text properties:
// 1. multivalue properties.
@@ -139,19 +139,19 @@ class Text extends Property {
foreach($val as &$item) {
if (!is_array($item)) {
- $item = array($item);
+ $item = [$item];
}
foreach($item as &$subItem) {
$subItem = strtr(
$subItem,
- array(
+ [
'\\' => '\\\\',
';' => '\;',
',' => '\,',
"\n" => '\n',
"\r" => "",
- )
+ ]
);
}
$item = implode(',', $item);
@@ -175,10 +175,9 @@ class Text extends Property {
// array-item. Multi-value text should be returned as multiple items in
// the top-array.
if (in_array($this->name, $this->structuredValues)) {
- return array($this->getParts());
- } else {
- return $this->getParts();
+ return [$this->getParts()];
}
+ return $this->getParts();
}
@@ -315,11 +314,11 @@ class Text extends Property {
$minimum = $this->minimumPropertyValues[$this->name];
$parts = $this->getParts();
if (count($parts) < $minimum) {
- $warnings[] = array(
+ $warnings[] = [
'level' => 1,
'message' => 'This property must have at least ' . $minimum . ' components. It only has ' . count($parts),
'node' => $this,
- );
+ ];
if ($options & self::REPAIR) {
$parts = array_pad($parts, $minimum, '');
$this->setParts($parts);
diff --git a/lib/Property/VCard/DateAndOrTime.php b/lib/Property/VCard/DateAndOrTime.php
index f9572b0..1118863 100644
--- a/lib/Property/VCard/DateAndOrTime.php
+++ b/lib/Property/VCard/DateAndOrTime.php
@@ -200,7 +200,7 @@ class DateAndOrTime extends Property {
// Early exit if we don't have a time string.
if (is_null($parts['hour']) && is_null($parts['minute']) && is_null($parts['second'])) {
- return array($dateStr);
+ return [$dateStr];
}
$dateStr.='T';
@@ -242,7 +242,7 @@ class DateAndOrTime extends Property {
$dateStr.=$parts['timezone'];
}
- return array($dateStr);
+ return [$dateStr];
}
diff --git a/lib/timezonedata/exchangezones.php b/lib/timezonedata/exchangezones.php
index a56c574..3f2ceb3 100644
--- a/lib/timezonedata/exchangezones.php
+++ b/lib/timezonedata/exchangezones.php
@@ -11,83 +11,83 @@
* @copyright Copyright (C) 2007-2014 fruux GmbH (https://fruux.com/).
* @license http://sabre.io/license/ Modified BSD License
*/
-return array(
- 'Universal Coordinated Time' => 'UTC',
- 'Casablanca, Monrovia' => 'Africa/Casablanca',
- 'Greenwich Mean Time: Dublin, Edinburgh, Lisbon, London' => 'Europe/Lisbon',
- 'Greenwich Mean Time; Dublin, Edinburgh, London' => 'Europe/London',
- 'Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna' => 'Europe/Berlin',
- 'Belgrade, Pozsony, Budapest, Ljubljana, Prague' => 'Europe/Prague',
- 'Brussels, Copenhagen, Madrid, Paris' => 'Europe/Paris',
- 'Paris, Madrid, Brussels, Copenhagen' => 'Europe/Paris',
- 'Prague, Central Europe' => 'Europe/Prague',
- 'Sarajevo, Skopje, Sofija, Vilnius, Warsaw, Zagreb' => 'Europe/Sarajevo',
- 'West Central Africa' => 'Africa/Luanda', // This was a best guess
- 'Athens, Istanbul, Minsk' => 'Europe/Athens',
- 'Bucharest' => 'Europe/Bucharest',
- 'Cairo' => 'Africa/Cairo',
- 'Harare, Pretoria' => 'Africa/Harare',
- 'Helsinki, Riga, Tallinn' => 'Europe/Helsinki',
- 'Israel, Jerusalem Standard Time' => 'Asia/Jerusalem',
- 'Baghdad' => 'Asia/Baghdad',
- 'Arab, Kuwait, Riyadh' => 'Asia/Kuwait',
- 'Moscow, St. Petersburg, Volgograd' => 'Europe/Moscow',
- 'East Africa, Nairobi' => 'Africa/Nairobi',
- 'Tehran' => 'Asia/Tehran',
- 'Abu Dhabi, Muscat' => 'Asia/Muscat', // Best guess
- 'Baku, Tbilisi, Yerevan' => 'Asia/Baku',
- 'Kabul' => 'Asia/Kabul',
- 'Ekaterinburg' => 'Asia/Yekaterinburg',
- 'Islamabad, Karachi, Tashkent' => 'Asia/Karachi',
+return [
+ 'Universal Coordinated Time' => 'UTC',
+ 'Casablanca, Monrovia' => 'Africa/Casablanca',
+ 'Greenwich Mean Time: Dublin, Edinburgh, Lisbon, London' => 'Europe/Lisbon',
+ 'Greenwich Mean Time; Dublin, Edinburgh, London' => 'Europe/London',
+ 'Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna' => 'Europe/Berlin',
+ 'Belgrade, Pozsony, Budapest, Ljubljana, Prague' => 'Europe/Prague',
+ 'Brussels, Copenhagen, Madrid, Paris' => 'Europe/Paris',
+ 'Paris, Madrid, Brussels, Copenhagen' => 'Europe/Paris',
+ 'Prague, Central Europe' => 'Europe/Prague',
+ 'Sarajevo, Skopje, Sofija, Vilnius, Warsaw, Zagreb' => 'Europe/Sarajevo',
+ 'West Central Africa' => 'Africa/Luanda', // This was a best guess
+ 'Athens, Istanbul, Minsk' => 'Europe/Athens',
+ 'Bucharest' => 'Europe/Bucharest',
+ 'Cairo' => 'Africa/Cairo',
+ 'Harare, Pretoria' => 'Africa/Harare',
+ 'Helsinki, Riga, Tallinn' => 'Europe/Helsinki',
+ 'Israel, Jerusalem Standard Time' => 'Asia/Jerusalem',
+ 'Baghdad' => 'Asia/Baghdad',
+ 'Arab, Kuwait, Riyadh' => 'Asia/Kuwait',
+ 'Moscow, St. Petersburg, Volgograd' => 'Europe/Moscow',
+ 'East Africa, Nairobi' => 'Africa/Nairobi',
+ 'Tehran' => 'Asia/Tehran',
+ 'Abu Dhabi, Muscat' => 'Asia/Muscat', // Best guess
+ 'Baku, Tbilisi, Yerevan' => 'Asia/Baku',
+ 'Kabul' => 'Asia/Kabul',
+ 'Ekaterinburg' => 'Asia/Yekaterinburg',
+ 'Islamabad, Karachi, Tashkent' => 'Asia/Karachi',
'Kolkata, Chennai, Mumbai, New Delhi, India Standard Time' => 'Asia/Calcutta',
- 'Kathmandu, Nepal' => 'Asia/Kathmandu',
- 'Almaty, Novosibirsk, North Central Asia' => 'Asia/Almaty',
- 'Astana, Dhaka' => 'Asia/Dhaka',
- 'Sri Jayawardenepura, Sri Lanka' => 'Asia/Colombo',
- 'Rangoon' => 'Asia/Rangoon',
- 'Bangkok, Hanoi, Jakarta' => 'Asia/Bangkok',
- 'Krasnoyarsk' => 'Asia/Krasnoyarsk',
- 'Beijing, Chongqing, Hong Kong SAR, Urumqi' => 'Asia/Shanghai',
- 'Irkutsk, Ulaan Bataar' => 'Asia/Irkutsk',
- 'Kuala Lumpur, Singapore' => 'Asia/Singapore',
- 'Perth, Western Australia' => 'Australia/Perth',
- 'Taipei' => 'Asia/Taipei',
- 'Osaka, Sapporo, Tokyo' => 'Asia/Tokyo',
- 'Seoul, Korea Standard time' => 'Asia/Seoul',
- 'Yakutsk' => 'Asia/Yakutsk',
- 'Adelaide, Central Australia' => 'Australia/Adelaide',
- 'Darwin' => 'Australia/Darwin',
- 'Brisbane, East Australia' => 'Australia/Brisbane',
- 'Canberra, Melbourne, Sydney, Hobart (year 2000 only)' => 'Australia/Sydney',
- 'Guam, Port Moresby' => 'Pacific/Guam',
- 'Hobart, Tasmania' => 'Australia/Hobart',
- 'Vladivostok' => 'Asia/Vladivostok',
- 'Magadan, Solomon Is., New Caledonia' => 'Asia/Magadan',
- 'Auckland, Wellington' => 'Pacific/Auckland',
- 'Fiji Islands, Kamchatka, Marshall Is.' => 'Pacific/Fiji',
- 'Nuku\'alofa, Tonga' => 'Pacific/Tongatapu',
- 'Azores' => 'Atlantic/Azores',
- 'Cape Verde Is.' => 'Atlantic/Cape_Verde',
- 'Mid-Atlantic' => 'America/Noronha',
- 'Brasilia' => 'America/Sao_Paulo', // Best guess
- 'Buenos Aires' => 'America/Argentina/Buenos_Aires',
- 'Greenland' => 'America/Godthab',
- 'Newfoundland' => 'America/St_Johns',
- 'Atlantic Time (Canada)' => 'America/Halifax',
- 'Caracas, La Paz' => 'America/Caracas',
- 'Santiago' => 'America/Santiago',
- 'Bogota, Lima, Quito' => 'America/Bogota',
- 'Eastern Time (US & Canada)' => 'America/New_York',
- 'Indiana (East)' => 'America/Indiana/Indianapolis',
- 'Central America' => 'America/Guatemala',
- 'Central Time (US & Canada)' => 'America/Chicago',
- 'Mexico City, Tegucigalpa' => 'America/Mexico_City',
- 'Saskatchewan' => 'America/Edmonton',
- 'Arizona' => 'America/Phoenix',
- 'Mountain Time (US & Canada)' => 'America/Denver', // Best guess
- 'Pacific Time (US & Canada); Tijuana' => 'America/Los_Angeles', // Best guess
- 'Alaska' => 'America/Anchorage',
- 'Hawaii' => 'Pacific/Honolulu',
- 'Midway Island, Samoa' => 'Pacific/Midway',
- 'Eniwetok, Kwajalein, Dateline Time' => 'Pacific/Kwajalein',
-);
+ 'Kathmandu, Nepal' => 'Asia/Kathmandu',
+ 'Almaty, Novosibirsk, North Central Asia' => 'Asia/Almaty',
+ 'Astana, Dhaka' => 'Asia/Dhaka',
+ 'Sri Jayawardenepura, Sri Lanka' => 'Asia/Colombo',
+ 'Rangoon' => 'Asia/Rangoon',
+ 'Bangkok, Hanoi, Jakarta' => 'Asia/Bangkok',
+ 'Krasnoyarsk' => 'Asia/Krasnoyarsk',
+ 'Beijing, Chongqing, Hong Kong SAR, Urumqi' => 'Asia/Shanghai',
+ 'Irkutsk, Ulaan Bataar' => 'Asia/Irkutsk',
+ 'Kuala Lumpur, Singapore' => 'Asia/Singapore',
+ 'Perth, Western Australia' => 'Australia/Perth',
+ 'Taipei' => 'Asia/Taipei',
+ 'Osaka, Sapporo, Tokyo' => 'Asia/Tokyo',
+ 'Seoul, Korea Standard time' => 'Asia/Seoul',
+ 'Yakutsk' => 'Asia/Yakutsk',
+ 'Adelaide, Central Australia' => 'Australia/Adelaide',
+ 'Darwin' => 'Australia/Darwin',
+ 'Brisbane, East Australia' => 'Australia/Brisbane',
+ 'Canberra, Melbourne, Sydney, Hobart (year 2000 only)' => 'Australia/Sydney',
+ 'Guam, Port Moresby' => 'Pacific/Guam',
+ 'Hobart, Tasmania' => 'Australia/Hobart',
+ 'Vladivostok' => 'Asia/Vladivostok',
+ 'Magadan, Solomon Is., New Caledonia' => 'Asia/Magadan',
+ 'Auckland, Wellington' => 'Pacific/Auckland',
+ 'Fiji Islands, Kamchatka, Marshall Is.' => 'Pacific/Fiji',
+ 'Nuku\'alofa, Tonga' => 'Pacific/Tongatapu',
+ 'Azores' => 'Atlantic/Azores',
+ 'Cape Verde Is.' => 'Atlantic/Cape_Verde',
+ 'Mid-Atlantic' => 'America/Noronha',
+ 'Brasilia' => 'America/Sao_Paulo', // Best guess
+ 'Buenos Aires' => 'America/Argentina/Buenos_Aires',
+ 'Greenland' => 'America/Godthab',
+ 'Newfoundland' => 'America/St_Johns',
+ 'Atlantic Time (Canada)' => 'America/Halifax',
+ 'Caracas, La Paz' => 'America/Caracas',
+ 'Santiago' => 'America/Santiago',
+ 'Bogota, Lima, Quito' => 'America/Bogota',
+ 'Eastern Time (US & Canada)' => 'America/New_York',
+ 'Indiana (East)' => 'America/Indiana/Indianapolis',
+ 'Central America' => 'America/Guatemala',
+ 'Central Time (US & Canada)' => 'America/Chicago',
+ 'Mexico City, Tegucigalpa' => 'America/Mexico_City',
+ 'Saskatchewan' => 'America/Edmonton',
+ 'Arizona' => 'America/Phoenix',
+ 'Mountain Time (US & Canada)' => 'America/Denver', // Best guess
+ 'Pacific Time (US & Canada); Tijuana' => 'America/Los_Angeles', // Best guess
+ 'Alaska' => 'America/Anchorage',
+ 'Hawaii' => 'Pacific/Honolulu',
+ 'Midway Island, Samoa' => 'Pacific/Midway',
+ 'Eniwetok, Kwajalein, Dateline Time' => 'Pacific/Kwajalein',
+];
diff --git a/lib/timezonedata/lotuszones.php b/lib/timezonedata/lotuszones.php
index 15147f5..b92ab9c 100644
--- a/lib/timezonedata/lotuszones.php
+++ b/lib/timezonedata/lotuszones.php
@@ -7,7 +7,7 @@
* @copyright Copyright (C) 2007-2014 fruux GmbH (https://fruux.com/).
* @license http://sabre.io/license/ Modified BSD License
*/
-return array(
+return [
'Dateline' => 'Etc/GMT-12',
'Samoa' => 'Pacific/Apia',
'Hawaiian' => 'Pacific/Honolulu',
@@ -98,4 +98,4 @@ return array(
'Fiji' => 'Pacific/Fiji',
'New Zealand' => 'Pacific/Auckland',
'Tonga' => 'Pacific/Tongatapu',
-);
+];
diff --git a/lib/timezonedata/php-bc.php b/lib/timezonedata/php-bc.php
index 0eb4725..a70b531 100644
--- a/lib/timezonedata/php-bc.php
+++ b/lib/timezonedata/php-bc.php
@@ -14,7 +14,7 @@
* @copyright Copyright (C) 2007-2014 fruux GmbH (https://fruux.com/).
* @license http://sabre.io/license/ Modified BSD License
*/
- return array(
+ return [
'Africa/Asmera',
'Africa/Timbuktu',
'America/Argentina/ComodRivadavia',
@@ -150,4 +150,4 @@
'US/Pacific-New',
'US/Samoa',
'WET',
-);
+];
diff --git a/lib/timezonedata/php-workaround.php b/lib/timezonedata/php-workaround.php
index d86a98e..7015324 100644
--- a/lib/timezonedata/php-workaround.php
+++ b/lib/timezonedata/php-workaround.php
@@ -13,7 +13,7 @@
* @copyright Copyright (C) 2007-2014 fruux GmbH (https://fruux.com/).
* @license http://sabre.io/license/ Modified BSD License
*/
-return array(
+return [
'CST6CDT' => 'America/Chicago',
'Cuba' => 'America/Havana',
'Egypt' => 'Africa/Cairo',
@@ -42,4 +42,4 @@ return array(
'Universal' => 'UTC',
'W-SU' => 'Europe/Moscow',
'Zulu' => 'UTC',
-);
+];
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/php-sabre-vobject.git
More information about the Pkg-owncloud-commits
mailing list