diff --git a/app/views/users/_general.html.erb b/app/views/users/_general.html.erb
old mode 100644
new mode 100755
index 793668e..c4507cb
--- a/app/views/users/_general.html.erb
+++ b/app/views/users/_general.html.erb
@@ -4,10 +4,17 @@
- Age
- <%= @user.age %>
- - Country
- - <%= @user.country %>
- - Town
- - <%= @user.profile.town %>
+
+ <% if !@user.country.blank? %>
+ - Country
+ - <%= @user.country %>
+ <% end %>
+
+ <% if !@user.profile.town.blank? %>
+ - Town
+ - <%= @user.profile.town %>
+ <% end %>
+
- SteamID
-
<%= @user.steamid %>
@@ -15,9 +22,12 @@
<%= link_to "Search for Steam Account" %>
- - Stream
- - <%= @user.profile.stream.blank? ? "No Stream Provided" : @user.profile.stream %>
-
+
+ <% if !@user.profile.stream.blank? %>
+ - Stream
+ - <%= @user.profile.stream %>
+
+ <% end %>
Contact
diff --git a/spec/features/users/stream_spec.rb b/spec/features/users/stream_spec.rb
old mode 100644
new mode 100755
index 136dfb0..4983ed6
--- a/spec/features/users/stream_spec.rb
+++ b/spec/features/users/stream_spec.rb
@@ -7,7 +7,7 @@ feature "User Stream Information" do
feature "stream administration" do
scenario "user updates their stream" do
visit user_path(user)
- expect(page).to have_content("No Stream Provided")
+ expect(page.html).to_not include("Stream")
fill_login_form(user, password)
click_button submit(:user, :login)
visit edit_user_path(user)
@@ -17,6 +17,7 @@ feature "User Stream Information" do
click_button "Update Profile"
expect(page).to have_content(I18n.t(:users_update))
visit user_path(user)
+ expect(page.html).to include("Stream")
expect(page).to have_content(stream_url)
end
end