Skip to content

Commit

Permalink
Moved dollar sign inside curly braces for all embedded strings in Con…
Browse files Browse the repository at this point in the history
…vertTaxbreakdown.php

This will prevent deprecation warnings in PHP 8.2 and is consistent with all other embedded strings in ConvertTaxbreakdown.php and the rest of the project
  • Loading branch information
arie-piscator authored Nov 8, 2023
1 parent 699bc88 commit dfdf1d2
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions packages/core/database/state/ConvertTaxbreakdown.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public function run()

if ($this->canRunOnOrders()) {
DB::table("{$prefix}orders")
->whereJsonContainsKey("${prefix}orders.tax_breakdown->[0]->total")
->whereJsonContainsKey("{$prefix}orders.tax_breakdown->[0]->total")
->orderBy('id')
->chunk(500, function ($rows) use ($prefix, $updateTime) {
foreach ($rows as $row) {
Expand All @@ -43,14 +43,14 @@ public function run()

if ($this->canRunOnOrderLines()) {
DB::table("{$prefix}order_lines")
->whereJsonContainsKey("${prefix}order_lines.tax_breakdown->[0]->total")
->orderBy("${prefix}order_lines.id")
->whereJsonContainsKey("{$prefix}order_lines.tax_breakdown->[0]->total")
->orderBy("{$prefix}order_lines.id")
->select(
"${prefix}order_lines.id",
"${prefix}order_lines.tax_breakdown",
"${prefix}orders.currency_code",
"{$prefix}order_lines.id",
"{$prefix}order_lines.tax_breakdown",
"{$prefix}orders.currency_code",
)
->join("${prefix}orders", "${prefix}order_lines.order_id", '=', "${prefix}orders.id")
->join("{$prefix}orders", "{$prefix}order_lines.order_id", '=', "{$prefix}orders.id")
->chunk(500, function ($rows) use ($prefix, $updateTime) {
DB::transaction(function () use ($prefix, $updateTime, $rows) {
foreach ($rows as $row) {
Expand Down

0 comments on commit dfdf1d2

Please sign in to comment.