Closed asmecher closed 6 years ago
I believe I have already fixed this in the past. (see https://github.com/kaschioudi/ojs3-markup/blob/master/classes/MarkupConversionHelper.inc.php#L107) Is there a chance you're not running the latest version of the code ?
Yes, it looks like it's fixed in HEAD
. But shouldn't that be an array initialization, rather than an empty string?
But shouldn't that be an array initialization, rather than an empty string?
in this case, it doesn't really matter because this array goes straight to OTS.
You're right, it won't behave badly, this is just for clarity's sake. Running
$var = '';
$var[1] = 'something';
...will juggle $var
from a string ''
into an array ['something']
, but it only behaves as expected because $var
starts out as an empty string. If $var
contains anything else, then $var[1]
will be treated as a string index and you'll get a string with some contents replaced.
Since $abstracts
is supposed to contain a list, initializing it to an empty list makes more sense, I think.
fixed in master
and ojs-stable-3_1_0
branches.
PHP Notice: Undefined variable: abstracts in /home/asmecher/git/ojs/plugins/generic/markup/classes/MarkupConversionHelper.inc.php on line 117
(This may have been a submission without any abstracts.)