Skip to content

Commit b6db6f7

Browse files
authored
Use str_replace instead of Str::replace (#268)
Str::replace introduced in Laravel 8.41.0, we should also support lower versions.
1 parent fadb14a commit b6db6f7

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/Provider/PaymentServiceProvider.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
use Shetabit\Multipay\Payment;
66
use Illuminate\Support\ServiceProvider;
77
use Illuminate\Support\Facades\Blade;
8-
use Illuminate\Support\Str;
98
use Shetabit\Multipay\Request;
109
use Shetabit\Payment\Events\InvoicePurchasedEvent;
1110
use Shetabit\Payment\Events\InvoiceVerifiedEvent;
@@ -67,7 +66,7 @@ public function register()
6766
// use blade to render redirection form
6867
Payment::setRedirectionFormViewRenderer(function ($view, $action, $inputs, $method) {
6968
return Blade::render(
70-
Str::replace('</form>', '@csrf</form>', file_get_contents($view)),
69+
str_replace('</form>', '@csrf</form>', file_get_contents($view)),
7170
[
7271
'action' => $action,
7372
'inputs' => $inputs,

0 commit comments

Comments
 (0)