<%= form_for(current_user, as: :user, url: registration_path(:user), html: { method: :put }) do |f| %> <% if current_user.errors.any? %>
Please fix the following errors:
<%= devise_error_messages! %>
<% end %>
<%= render partial: 'devise/registrations/panes/preferences', locals: { f: f } %>
<%= f.submit "Save changes", class: 'btn blue' %> <%= link_to "Cancel", :back, class: 'btn grey' %>
<% end %>