What PHP version do you have?
Maybe it comes from kind of abandoned option... or outdated version. I clearly see this syntax is still
not abandoned in new PHP releases.
As of PHP 5.4 you can also use the short array syntax, which replaces array() with [].
I.e. it means these codes below should be equal in parsing, but obviously on your side they aren't (if the error is exactly about this line):
$array = array(
"foo" => "bar",
"bar" => "foo",
);
// as of PHP 5.4
$array = [
"foo" => "bar",
"bar" => "foo",
];
You could just try to update on the error line:
$replace = [
...
];
with this:
$replace = array(
...
);
(leave all internal codes intact on the '...' place).