Skip to content
This repository has been archived by the owner on Nov 29, 2023. It is now read-only.

Commit

Permalink
Fix breaking changes from K3.6
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastiangreger committed Sep 22, 2021
1 parent 2f73e17 commit d52ffd6
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion lib/Commention.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,13 @@ public function sourceFormatted(string $anonymous = null): ?string

// Use single brackets (instead of double) to match the behavior
// of Kirby’s `tt()` helper function.
return Str::template($translation, $replace, null, '{', '}');
if (substr(\Kirby\Cms\App::version(), 0, 3) === '3.6') {
return Str::template($translation, $replace, ['fallback' => null, 'start' => '{', 'end' => '}']);
}
/* TODO: only keep array version once K3.6 is out */
else {
return Str::template($translation, $replace, null, '{', '}');
}
}

/**
Expand Down

0 comments on commit d52ffd6

Please sign in to comment.