Skip to content
This repository has been archived by the owner on Feb 23, 2019. It is now read-only.

Commit

Permalink
Validate stristr needle (#558)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ivanner authored and Furniel committed Jul 3, 2018
1 parent f086e8d commit a0a7109
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/Minify/Minify/IgnoredCommentPreserver.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ protected function _callback($match) {

protected function _isIgnoredComment(&$comment) {
foreach ($this->_ignoredComments as $ignoredComment) {
if (stristr($comment, $ignoredComment) !== false) {
if (!empty($ignoredComment) && stristr($comment, $ignoredComment) !== false) {
return true;
}
}
Expand Down

0 comments on commit a0a7109

Please sign in to comment.