[Pkg-owncloud-commits] [php-sabre-vobject] 34/341: Simplify two conditions.
David Prévot
taffit at moszumanska.debian.org
Tue Aug 11 13:35:30 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 8ac625fa869029f1b9768256c2f38eb1d04def3e
Author: Ivan Enderlin <ivan.enderlin at hoa-project.net>
Date: Tue Nov 18 11:20:36 2014 +0100
Simplify two conditions.
---
lib/Document.php | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)
diff --git a/lib/Document.php b/lib/Document.php
index 3624037..fd8ca6b 100644
--- a/lib/Document.php
+++ b/lib/Document.php
@@ -209,12 +209,14 @@ abstract class Document extends Component {
$class = $this->getClassNameForPropertyValue($valueType);
}
- if (is_null($class) && isset($parameters['VALUE'])) {
- // If a VALUE parameter is supplied, we should use that.
- $class = $this->getClassNameForPropertyValue($parameters['VALUE']);
- }
if (is_null($class)) {
- $class = $this->getClassNameForPropertyName($name);
+ // If a VALUE parameter is supplied, we should use that.
+ if (isset($parameters['VALUE'])) {
+ $class = $this->getClassNameForPropertyValue($parameters['VALUE']);
+ }
+ else {
+ $class = $this->getClassNameForPropertyName($name);
+ }
}
if (is_null($parameters)) $parameters = [];
--
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