From a46820e98f3081c0d9931276cf9cd466264eb928 Mon Sep 17 00:00:00 2001 From: Toby Allen Date: Tue, 13 Aug 2024 13:23:13 +0100 Subject: [PATCH] use str::of instead of str() --- src/Console/CheckSQLGrammerDate.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Console/CheckSQLGrammerDate.php b/src/Console/CheckSQLGrammerDate.php index b89094c..303a4ad 100644 --- a/src/Console/CheckSQLGrammerDate.php +++ b/src/Console/CheckSQLGrammerDate.php @@ -4,7 +4,7 @@ use Illuminate\Console\Command; - +use Illuminate\Support\Str; /** * There is an international date format Y-m-d that is supposed to be universal, however the MSSQL implementation is flawed * and is not universal and incorrect interprets it as Y-d-m which is beyond idiotic. @@ -65,7 +65,7 @@ public function handle() { $filetocheck = base_path('vendor\laravel\framework\src\Illuminate\Database\Query\Grammars\SqlServerGrammar.php'); if (file_exists($filetocheck)){ - $file_txt = Str(file_get_contents($filetocheck)); + $file_txt = Str::of(file_get_contents($filetocheck)); $datestr = 'return \'Y-m-d H:i:s.v\';'; if ($file_txt->contains($datestr)){ if ($this->option('update')){ @@ -73,9 +73,9 @@ public function handle() file_put_contents($filetocheck,$UpdatedFile_txt); $this->comment(" -********************************** +********************************** Incorrect Date Format value found -********************************** +********************************** File on disk: $filetocheck"); $this->info(' ------------------