accept 'avatar' as well as 'avatarUrl' for avatar field

This commit is contained in:
Aaron van Meerten 2017-07-13 14:45:55 -05:00 committed by Дамян Минков
parent d335669afe
commit d752e8b864
2 changed files with 4 additions and 4 deletions

View File

@ -114,10 +114,10 @@ function _setTokenData() {
const { caller } = state['features/jwt'];
if (caller) {
const { avatarUrl, email, name } = caller;
const { avatarUrl, avatar, email, name } = caller;
APP.settings.setEmail((email || '').trim(), true);
APP.settings.setAvatarUrl((avatarUrl || '').trim());
APP.settings.setAvatarUrl((avatarUrl || avatar || '').trim());
APP.settings.setDisplayName((name || '').trim(), true);
}
}

View File

@ -158,7 +158,7 @@ class CallOverlay extends Component {
*/
render() {
const { className, ringing } = this.state;
const { avatarUrl, name } = this.props._callee;
const { avatarUrl, avatar, name } = this.props._callee;
return (
<Container
@ -171,7 +171,7 @@ class CallOverlay extends Component {
</Text>
<Avatar
{ ...this._style('ringing__avatar') }
uri = { avatarUrl } />
uri = { avatarUrl || avatar } />
<Container
{ ...this._style('ringing__caller-info') }>
<Text