1
0
Fork 0
mirror of https://github.com/kbparagua/paloma synced 2023-03-27 23:21:17 -04:00

Check for the existence of Paloma in the hook Javascript

This commit is contained in:
Julien Vanier 2015-01-22 14:21:22 -05:00
parent 2ce88be5a5
commit 61e4ea1413

View file

@ -3,6 +3,11 @@
<div class="js-paloma-hook" data-id="<%= id %>">
<script type="text/javascript">
(function(){
// Do not continue if Paloma not found.
if (window['Paloma'] === undefined) {
return true;
}
Paloma.env = '<%= Rails.env %>';
// Remove any callback details if any