Skip to content

Commit 80dddf4

Browse files
author
Admin
committed
1 parent 2051539 commit 80dddf4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

illuminate/Database/Schema/Grammars/Grammar.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -314,12 +314,12 @@ protected function getDefaultValue($value)
314314
}
315315

316316
if ($value instanceof BackedEnum) {
317-
return "'{$value->value}'";
317+
return "'" . \str_replace("'", "''", $value->value) . "'";
318318
}
319319

320320
return is_bool($value)
321321
? "'" . (int)$value . "'"
322-
: "'" . (string)$value . "'";
322+
: "'" . \str_replace("'", "''", $value) . "'";
323323
}
324324

325325
/**

0 commit comments

Comments
 (0)