FIX: do not show website name on TL0 profile

This commit is contained in:
Arpit Jalan 2017-06-04 18:28:36 +05:30
parent b93a4e369d
commit a10c939775
2 changed files with 2 additions and 1 deletions

View File

@ -115,6 +115,7 @@ class UserSerializer < BasicUserSerializer
:bio_excerpt,
:location,
:website,
:website_name,
:profile_background,
:card_background

View File

@ -8,7 +8,7 @@ describe UserSerializer do
let(:serializer) { UserSerializer.new(user, scope: Guardian.new, root: false) }
let(:json) { serializer.as_json }
let(:untrusted_attributes) { %i{bio_raw bio_cooked bio_excerpt location website profile_background card_background} }
let(:untrusted_attributes) { %i{bio_raw bio_cooked bio_excerpt location website website_name profile_background card_background} }
it "doesn't serialize untrusted attributes" do
untrusted_attributes.each { |attr| expect(json).not_to have_key(attr) }