/users: fix exception when last_ip_addr is nil.

This commit is contained in:
evazion
2020-12-26 11:16:19 -06:00
parent fd18291382
commit 57e70e5b82

View File

@@ -17,7 +17,9 @@
<% end %>
<% if policy(IpAddress).show? %>
<% t.column "IP" do |user| %>
<%= link_to user.last_ip_addr, ip_address_path(user.last_ip_addr) %>
<% if user.last_ip_addr.present? %>
<%= link_to user.last_ip_addr, ip_address_path(user.last_ip_addr) %>
<% end %>
<% end %>
<% end %>
<% t.column "Posts" do |user| %>