diff --git a/src/components/user_profile/user_profile.js b/src/components/user_profile/user_profile.js index eaadca72..cbb11853 100644 --- a/src/components/user_profile/user_profile.js +++ b/src/components/user_profile/user_profile.js @@ -157,6 +157,8 @@ const UserProfile = { const errorMessage = get(reason, 'error.error') if (errorMessage === 'No user with such user_id') { // Known error this.error = this.$t('user_profile.profile_does_not_exist') + } else if (errorMessage == 'This API requires an authenticated user') { + this.error = this.$t('user_profile.unauthorized') } else if (errorMessage) { this.error = errorMessage } else { diff --git a/src/i18n/en.json b/src/i18n/en.json index 948419ab..a887d2cf 100644 --- a/src/i18n/en.json +++ b/src/i18n/en.json @@ -1202,6 +1202,7 @@ "user_profile": { "profile_does_not_exist": "Sorry, this profile does not exist.", "profile_loading_error": "Sorry, there was an error loading this profile.", + "unauthorized": "Please log in to view this profile.", "timeline_title": "User timeline", "field_validated": "Link Verified" },