We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 539a865 commit 6f8814fCopy full SHA for 6f8814f
src/Api/Element.php
@@ -127,6 +127,13 @@ public function cast($value)
127
if ($methods === null) {
128
$methods = [
129
self::TYPE_DATE => static function ($value) {
130
+ /**
131
+ * In case the date value consists only of zeros, this
132
+ * is most likely a mistake of the SAP remote function.
133
+ */
134
+ if (preg_match('~^[0]+$~', $value)) {
135
+ return null;
136
+ }
137
return SapDateTime::createFromFormat(SapDateTime::SAP_DATE, $value);
138
},
139
self::TYPE_TIME => static function ($value) {
0 commit comments