From 83f6cc9d1bf495b126966244e5e3a46e9ad2c663 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebasti=C3=A1n=20Katzer?= Date: Fri, 27 Jan 2017 14:45:34 +0100 Subject: [PATCH] Fix wrong scope in overrideBackButton --- www/background-mode.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/www/background-mode.js b/www/background-mode.js index 1640481..edfa25c 100644 --- a/www/background-mode.js +++ b/www/background-mode.js @@ -165,7 +165,9 @@ exports.moveToForeground = function () { * @return [ Void ] */ exports.overrideBackButton = function () { - document.addEventListener('backbutton', this.moveToBackground, false); + document.addEventListener('backbutton', function() { + exports.moveToBackground(); + }, false); }; /**