diff --git a/app/controllers/user_signatures_controller.rb b/app/controllers/user_signatures_controller.rb index 69d0e795..e7c5b962 100644 --- a/app/controllers/user_signatures_controller.rb +++ b/app/controllers/user_signatures_controller.rb @@ -28,6 +28,12 @@ class UserSignaturesController < ApplicationController end end + def destroy + @user_config.destroy + + redirect_to settings_profile_index_path, notice: 'Signature has been removed' + end + private def load_user_config diff --git a/app/views/profile/index.html.erb b/app/views/profile/index.html.erb index 96db7027..27ab55e8 100644 --- a/app/views/profile/index.html.erb +++ b/app/views/profile/index.html.erb @@ -25,7 +25,8 @@
Signature
<% signature = UserConfigs.load_signature(current_user) %> <% if signature %> -