Fix duplicate flash message on mobile profile edit

closes #7107
This commit is contained in:
Benjamin Neff 2016-09-17 23:35:59 +02:00 committed by Steffen van Bergerem
parent 5837919946
commit 8ee92e34aa
No known key found for this signature in database
GPG key ID: 2F08F75F9525C7E0
3 changed files with 6 additions and 9 deletions

View file

@ -21,6 +21,7 @@
* Prevent overflow of interaction avatars in the single post view [#7070](https://github.com/diaspora/diaspora/pull/7070)
* Fix moving publisher on first click after page load [#7094](https://github.com/diaspora/diaspora/pull/7094)
* Fix link to comment on report page [#7105](https://github.com/diaspora/diaspora/pull/7105)
* Fix duplicate flash message on mobile profile edit [#7107](https://github.com/diaspora/diaspora/pull/7107)
## Features
* Deleted comments will be removed when loading more comments [#7045](https://github.com/diaspora/diaspora/pull/7045)

View file

@ -28,14 +28,6 @@
});
});
- if mobile
.stream
- flash.each do |name, msg|
%div{:id => "flash_#{name}", :class => "expose"}
.message= msg
.stream
%p{:class => "conversation_#{name}"}= msg
%h3.inline
= t("profiles.edit.basic")
%span{ :title => t("profiles.edit.basic_hint") }

View file

@ -13,6 +13,10 @@
= link_to t("cancel"), local_or_remote_person_path(current_user.person), class: "btn btn-default"
= submit_tag t(".update_profile"), class: "btn btn-primary pull-right", id: "update_profile"
- flash.each do |name, msg|
.alert{class: "alert-#{flash_class name}", role: "alert"}
= msg
= form_tag profile_path, method: :put, multipart: true, id: "update_profile_form" do
= render "edit_public", profile: @profile, aspect: @aspect, person: @person, mobile: true
= render "edit_public", profile: @profile, aspect: @aspect, person: @person
= render "edit_private", person: @person, profile: @profile, aspect: @aspect, step: @step