summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorConstance Okoghenun <cokoghenun@gitlab.com>2018-05-07 13:46:25 +0100
committerConstance Okoghenun <cokoghenun@gitlab.com>2018-05-07 13:46:25 +0100
commitfe7e18185f1bd22ed6952d90ff4dede34b5c68f5 (patch)
treebc148c1466c5eb064358a34ba5bc682379f9fe15
parent6948b56cddaf0848345945003ffcbc8715c61a04 (diff)
downloadgitlab-ce-fe7e18185f1bd22ed6952d90ff4dede34b5c68f5.tar.gz
Fixed linit errors
-rw-r--r--app/assets/javascripts/pages/projects/wikis/components/delete_wiki_modal.vue36
-rw-r--r--app/views/projects/wikis/edit.html.haml8
-rw-r--r--spec/features/projects/wiki/user_deletes_wiki_page_spec.rb2
3 files changed, 23 insertions, 23 deletions
diff --git a/app/assets/javascripts/pages/projects/wikis/components/delete_wiki_modal.vue b/app/assets/javascripts/pages/projects/wikis/components/delete_wiki_modal.vue
index 85c14b6af77..1943113fc1b 100644
--- a/app/assets/javascripts/pages/projects/wikis/components/delete_wiki_modal.vue
+++ b/app/assets/javascripts/pages/projects/wikis/components/delete_wiki_modal.vue
@@ -34,7 +34,7 @@ export default {
{
pageTitle: `'${_.escape(this.pageTitle)}'`,
},
- false
+ false,
);
},
},
@@ -56,22 +56,22 @@ export default {
>
{{ message }}
<form
- ref="form"
- :action="deleteWikiUrl"
- method="post"
- class="form-horizontal js-requires-input"
- >
- <input
- ref="method"
- type="hidden"
- name="_method"
- value="delete"
- />
- <input
- type="hidden"
- name="authenticity_token"
- :value="csrfToken"
- />
- </form>
+ ref="form"
+ :action="deleteWikiUrl"
+ method="post"
+ class="form-horizontal js-requires-input"
+ >
+ <input
+ ref="method"
+ type="hidden"
+ name="_method"
+ value="delete"
+ />
+ <input
+ type="hidden"
+ name="authenticity_token"
+ :value="csrfToken"
+ />
+ </form>
</gl-modal>
</template>
diff --git a/app/views/projects/wikis/edit.html.haml b/app/views/projects/wikis/edit.html.haml
index abc8f7cc04b..35c7dc2984a 100644
--- a/app/views/projects/wikis/edit.html.haml
+++ b/app/views/projects/wikis/edit.html.haml
@@ -28,10 +28,10 @@
= link_to project_wiki_history_path(@project, @page), class: "btn" do
= s_("Wiki|Page history")
- if can?(current_user, :admin_wiki, @project)
- %button.btn.btn-danger{ data: { toggle: 'modal',
- target: '#delete-wiki-modal',
- delete_wiki_url: project_wiki_path(@project, @page),
- page_title: @page.title.capitalize },
+ %button.btn.btn-danger{ data: { toggle: 'modal',
+ target: '#delete-wiki-modal',
+ delete_wiki_url: project_wiki_path(@project, @page),
+ page_title: @page.title.capitalize },
id: 'delete-wiki-button',
type: 'button' }
= _('Delete')
diff --git a/spec/features/projects/wiki/user_deletes_wiki_page_spec.rb b/spec/features/projects/wiki/user_deletes_wiki_page_spec.rb
index fbae909a657..3c7c06aaeeb 100644
--- a/spec/features/projects/wiki/user_deletes_wiki_page_spec.rb
+++ b/spec/features/projects/wiki/user_deletes_wiki_page_spec.rb
@@ -14,7 +14,7 @@ feature 'User deletes wiki page', :js do
click_on('Edit')
click_on('Delete')
find('.js-modal-primary-action').click
-
+
expect(page).to have_content('Page was successfully deleted')
end
end