Skip to content
Permalink
Browse files

(cp 15d8a19) fixes #988 no more warning on PHP 7.3

This fix was initially only for branch 2.9, and branch master should have
received a new version of jshrink, but I forgot to do it before 2.10 and now
we have a regression in 2.10. This commit will be cherry-picked to 2.10 and
we also have it on master so that we don't have a new regression in 2.11 (in
case jshrink is not properly updated)
  • Loading branch information...
plegall committed Oct 14, 2019
1 parent e49c217 commit 9b695da86bb77e1982cf6818c3f5c4eb46b7b94a
Showing with 2 additions and 2 deletions.
  1. +2 −2 include/jshrink.class.php
@@ -192,7 +192,7 @@ protected function breakdownScript($js, $currentOptions)
case "\n":
// if the next line is something that can't stand alone
// preserve the newline
if(strpos('(-+{[@', $this->b) !== false)
if($this->b !== false && strpos('(-+{[@', $this->b) !== false)
{
echo $this->a;
$this->saveString();
@@ -239,7 +239,7 @@ protected function breakdownScript($js, $currentOptions)
if($this->a == '/' && ($this->b == '\'' || $this->b == '"'))
{
$this->saveRegex();
continue;
continue 3;
}
echo $this->a;

0 comments on commit 9b695da

Please sign in to comment.
You can’t perform that action at this time.