Merge pull request #482 from mathielen/patch-1

Impossible to access an attribute (\"custom_endpoint\") on a NULL variab...
This commit is contained in:
William Durand 2014-08-18 17:28:31 +02:00
commit 57ef437d25

View File

@ -396,7 +396,7 @@
{% else -%}
var endpoint = '{{ endpoint }}';
{% endif -%}
{% if authentication.custom_endpoint %}
{% if authentication and authentication.custom_endpoint %}
if ($('#api_endpoint') && typeof($('#api_endpoint').val()) != 'undefined') {
endpoint = $('#api_endpoint').val();
}