summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Zallmann <tzallmann@gitlab.com>2017-09-29 09:07:47 +0200
committerTim Zallmann <tzallmann@gitlab.com>2017-10-04 17:27:56 +0200
commit45b8266bcd97c1132a5012ca4df578df4999c6ac (patch)
treecec5d95998d7ebfc2a0fffa62d564384d1607126
parent9196a356ae675ab97e7ed49e48c1e59105ad2a81 (diff)
downloadgitlab-ce-45b8266bcd97c1132a5012ca4df578df4999c6ac.tar.gz
Fixed Eslint Errors
-rw-r--r--app/assets/javascripts/repo/components/repo_sidebar.vue8
1 files changed, 4 insertions, 4 deletions
diff --git a/app/assets/javascripts/repo/components/repo_sidebar.vue b/app/assets/javascripts/repo/components/repo_sidebar.vue
index 702056a7e3a..f741a8d46bc 100644
--- a/app/assets/javascripts/repo/components/repo_sidebar.vue
+++ b/app/assets/javascripts/repo/components/repo_sidebar.vue
@@ -25,11 +25,11 @@ export default {
methods: {
addPopEventListener() {
- window.addEventListener('popstate', (event) => {
- let selectedFile = this.files.find(file => {return location.pathname.indexOf(file.url) > -1});
+ window.addEventListener('popstate', () => {
+ let selectedFile = this.files.find(file => location.pathname.indexOf(file.url) > -1);
if (!selectedFile) {
// Maybe it is not in the current tree but in the opened tabs
- selectedFile = Store.openedFiles.find(file => {return location.pathname.indexOf(file.url) > -1});
+ selectedFile = Store.openedFiles.find(file => location.pathname.indexOf(file.url) > -1);
}
if (selectedFile) {
if (selectedFile.url !== this.activeFile.url) {
@@ -41,7 +41,7 @@ export default {
if (!isNaN(lineNumber)) {
Store.setActiveLine(lineNumber);
if (Store.isPreviewView()) {
- document.getElementById('L' + lineNumber).scrollIntoView();
+ document.getElementById(`L${lineNumber}`).scrollIntoView();
} else {
Helper.monacoInstance.setPosition({
lineNumber: this.activeLine,