Skip to content
Permalink
Browse files

correcting error in #41

  • Loading branch information
georgemandis committed Jun 25, 2018
1 parent a4e4f2c commit 3a8008711fe3948860a2a5ac1a3bde92e42fe273
Showing with 5 additions and 3 deletions.
  1. +5 −3 konami.js
@@ -4,7 +4,7 @@
* :: those situations that call for multiple easter eggs!
* Code: https://github.com/snaptortoise/konami-js
* Copyright (c) 2009 George Mandis (georgemandis.com, snaptortoise.com)
* Version: 1.6.0 (1/3/2018)
* Version: 1.6.1 (6/25/2018)
* Licensed under the MIT License (http://opensource.org/licenses/MIT)
* Tested in: Safari 4+, Google Chrome 4+, Firefox 3+, IE7+, Mobile Safari 2.2.1+ and Android
*/
@@ -33,6 +33,7 @@ var Konami = function (callback) {
input: "",
pattern: "38384040373937396665",
keydownHandler: function (e, ref_obj) {
console.log(this)
if (ref_obj) {
konami = ref_obj;
} // IE
@@ -41,13 +42,14 @@ var Konami = function (callback) {
konami.input = konami.input.substr((konami.input.length - konami.pattern.length));
}
if (konami.input === konami.pattern) {
konami.code(this._currentLink);
konami.code(konami._currentLink);
konami.input = '';
e.preventDefault();
return false;
}
},
load: function (link) {
this._currentLink = link;
this.addEvent(document, "keydown", this.keydownHandler, this);
this.iphone.load(link);
},
@@ -94,7 +96,7 @@ var Konami = function (callback) {
}
}
if (match) {
konami.iphone.code(this._currentLink);
konami.iphone.code(konami._currentLink);
}
}
},

0 comments on commit 3a80087

Please sign in to comment.
You can’t perform that action at this time.