- Fixed 'value' for SearchRequestOrderBy and also fixed a typo where SearchManual would not be set
This commit is contained in:
1 parent
4106c8db91
commit
3ba8a2a5d0
2 files changed
+17
-8
No files matched your search
@@ -12,12 +12,20 @@ class Datetime extends \DateTime implements EntityObjectInterface {
|
||||
{
|
||||
$value = $arguments[0];
|
||||
|
||||
# From Timestamp
|
||||
if ( is_numeric($value) ) {
|
||||
return new static("@$value");
|
||||
try {
|
||||
# From Timestamp
|
||||
if ( is_numeric($value) ) {
|
||||
$obj = new static("@$value");
|
||||
}
|
||||
else {
|
||||
$obj = new static($value);
|
||||
}
|
||||
}
|
||||
catch(\Throwable $ex) {
|
||||
throw new \Exception(sprintf("An error occured trying to instanciate from '%s'. %s", $value, $ex->getMessage()), $ex->getCode(), $ex);
|
||||
}
|
||||
|
||||
return new static($value);
|
||||
return $obj;
|
||||
}
|
||||
|
||||
public function save()
|
||||
|
||||
Reference in new issue
Block a user