lib/generators/bootswatch_rails/sorcery/templates/show.html.erb in bootswatch_rails-3.2.0.20 vs lib/generators/bootswatch_rails/sorcery/templates/show.html.erb in bootswatch_rails-3.2.0.21

- old
+ new

@@ -81,6 +81,8 @@ </tbody> </table> <%%= link_to t('actions.edit'), [:edit, @<%= name %>], class: 'btn btn-primary' %> <%%= link_to t('actions.back.index'), <%= table_name %>_path, class: 'btn btn-default' %> -<%%= link_to t('actions.destroy'), @<%= name %>, method: :delete, data: { confirm: t('actions.confirm') }, class: 'btn btn-danger' %> +<%%- if current_<%= name %>.status == :sysadm and @<%= name %> != current_<%= name %> -%> + <%%= link_to t('actions.destroy'), @<%= name %>, method: :delete, data: { confirm: t('actions.confirm') }, class: 'btn btn-danger' %> +<%%- end -%>