Permalink
Browse files

fix bug back button on rooms#edit

  • Loading branch information...
1 parent 516402e commit a99e80d448fdb6347f6594d32513076d42561ce7 @sakomoko committed Mar 4, 2012
Showing with 3 additions and 1 deletion.
  1. +3 −1 app/views/rooms/_form.html.haml
@@ -5,7 +5,9 @@
= f.input :static, as: :boolean
.form-actions
= f.button :submit, class: 'btn-primary'
- - if @parent.class == World
+ - if @parent.nil?
+ = link_to "back", @room, class: "btn"
+ - elsif @parent.class == World
= link_to "back", @parent, class: "btn"
- else
= link_to "back", [@parent.world, @parent], class: "btn"

0 comments on commit a99e80d

Please sign in to comment.