code: function (scope) {
        var self = this;
  
        // PATCH #1: fixing multiple keyup event trigger from single key press
        self.S('body').off('keyup.fndtn.reveal').on('keyup.fndtn.reveal', function ( event ) {
          var open_modal = self.S('[' + self.attr_name() + '].open'),
              settings = open_modal.data(self.attr_name(true) + '-init') || self.settings ;
          // PATCH #2: making sure that the close event can be called only while unlocked,
          //           so that multiple keyup.fndtn.reveal events don't prevent clean closing of the reveal window.
          if ( settings && event.which === 27  && settings.close_on_esc && !self.locked) { // 27 is the keycode for the Escape key
            self.close.call(self, open_modal);
          }
        });
  
        return true;
      }
docs: PATCH #3: turning on key up capture only when a reveal window is open