summaryrefslogtreecommitdiff
path: root/app/assets
diff options
context:
space:
mode:
authorWinnie Hellmann <winnie@gitlab.com>2017-10-26 13:04:42 +0200
committerWinnie Hellmann <winnie@gitlab.com>2017-10-26 13:04:42 +0200
commitfcc82ab601f1881558fc246f440f0ebe95bccab7 (patch)
treee6af5fac6381e413a33be4f956fceab524c9a25a /app/assets
parent06376254b0f1afbeb60724079e78db7e9ecba21f (diff)
downloadgitlab-ce-fcc82ab601f1881558fc246f440f0ebe95bccab7.tar.gz
Inline onSelectItem of NamespaceSelect
Diffstat (limited to 'app/assets')
-rw-r--r--app/assets/javascripts/namespace_select.js11
1 files changed, 4 insertions, 7 deletions
diff --git a/app/assets/javascripts/namespace_select.js b/app/assets/javascripts/namespace_select.js
index de987b3d947..959b52c5608 100644
--- a/app/assets/javascripts/namespace_select.js
+++ b/app/assets/javascripts/namespace_select.js
@@ -3,7 +3,6 @@ import Api from './api';
export default class NamespaceSelect {
constructor(opts) {
- this.onSelectItem = this.onSelectItem.bind(this);
var fieldName, showAny;
this.dropdown = $(opts.dropdown);
showAny = true;
@@ -51,12 +50,10 @@ export default class NamespaceSelect {
}
},
renderRow: this.renderRow,
- clicked: this.onSelectItem
+ clicked(options) {
+ const { e } = options;
+ return e.preventDefault();
+ },
});
}
-
- onSelectItem(options) {
- const { e } = options;
- return e.preventDefault();
- }
}