- $error = 'An error occurred while parsing JSON configuration file ('. $filepath .'): error code #';
- $error .= $errorCode. '<br>➜ <code>' . json_last_error_msg() .'</code>';
+ $error = sprintf(
+ 'An error occurred while parsing JSON configuration file (%s): error code #%d',
+ $filepath,
+ $errorCode
+ );
+ $error .= '<br>➜ <code>' . json_last_error_msg() .'</code>';