Skip to content

Commit faa4a41

Browse files
Update File.php
1 parent 5ff6951 commit faa4a41

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/File.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,9 @@ public final function put($data)
107107
$getPath = json_encode($data);
108108
}
109109

110-
return file_put_contents($this->getPath(), $getPath);
110+
if ($getPath != null && $getPath != "") {
111+
return file_put_contents($this->getPath(), $getPath);
112+
}
111113
}
112114

113115
public final function exists()
@@ -130,3 +132,4 @@ public final function remove()
130132
}
131133

132134
}
135+

0 commit comments

Comments
 (0)