Use .new_record? instead

This commit is contained in:
Alfredo Sumaran 2016-04-06 16:31:34 -05:00
parent d2afeb8dde
commit 946b4519c9
1 changed files with 2 additions and 2 deletions

View File

@ -1,6 +1,6 @@
- if controller.controller_path =~ /^groups/ && !@group.new_record?
- if controller.controller_path =~ /^groups/ && @group.persisted?
- label = 'This group'
- if controller.controller_path =~ /^projects/ && !@project.new_record?
- if controller.controller_path =~ /^projects/ && @project.persisted?
- label = 'This project'
.search.search-form{class: "#{'has-location-badge' if label.present?}"}