Fixed null avatar crash issue. Fixed editor title issue

This commit is contained in:
Mustafa Buyukcelebi 2019-11-02 12:11:41 +03:00
parent 5f06d06bd7
commit 2d35876b1e
2 changed files with 4 additions and 2 deletions

View File

@ -48,7 +48,7 @@ export default class TitleAreaView extends Component {
const { text, height } = this.state;
return (
<View style={globalStyles.containerHorizontal16}>
<View style={[globalStyles.containerHorizontal16, { height: Math.max(35, height) }]}>
<TextInput
style={[styles.textInput, { height: Math.max(35, height) }]}
placeholderTextColor="#c1c5c7"

View File

@ -61,7 +61,9 @@ class UserAvatarView extends Component {
let _size;
const _avatar = username
? {
uri: avatarUrl || (name === username ? avatar : getResizedAvatar(username, imageSize)),
uri:
avatarUrl ||
(name === username && avatar ? avatar : getResizedAvatar(username, imageSize)),
}
: DEFAULT_IMAGE;