Skip to content

Commit

Permalink
Merge pull request #5 from yoeunes/master
Browse files Browse the repository at this point in the history
fix composer.json and escape single in render function
  • Loading branch information
oriceon authored Jan 2, 2018
2 parents d570b55 + 92ce9dd commit 4ce3779
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,5 +34,5 @@
"Toastr": "Kamaln7\\Toastr\\Facades\\Toastr"
}
}
},
}
}
2 changes: 1 addition & 1 deletion src/Kamaln7/Toastr/Toastr.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public function render() {
}

// Toastr output
$output .= 'toastr.' . $notification['type'] . "('" . $notification['message'] . "'" . (isset($notification['title']) ? ", '" . str_replace("'", "\\'", htmlentities($notification['title'])) . "'" : null) . ');';
$output .= 'toastr.' . $notification['type'] . "('" . str_replace("'", "\\'", $notification['message']). "'" . (isset($notification['title']) ? ", '" . str_replace("'", "\\'", htmlentities($notification['title'])) . "'" : null) . ');';
}
$output .= '</script>';

Expand Down

0 comments on commit 4ce3779

Please sign in to comment.