File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed
src/components/CardAboutShelter Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -15,11 +15,7 @@ const CardAboutShelter = (props: ICardAboutShelter) => {
15
15
const { shelter } = props ;
16
16
17
17
const check = ( v ?: string | number | boolean | null ) => {
18
- return (
19
- ( v !== undefined && v !== null ) ||
20
- ( typeof v === 'number' && v === 0 ) ||
21
- ( typeof v === 'boolean' && v )
22
- ) ;
18
+ return v !== undefined && v !== null ;
23
19
} ;
24
20
25
21
return (
@@ -49,8 +45,10 @@ const CardAboutShelter = (props: ICardAboutShelter) => {
49
45
icon = { < PawPrint /> }
50
46
label = {
51
47
check ( shelter . petFriendly )
52
- ? 'O abrigo aceita animais'
53
- : 'O abrigo não aceita animais'
48
+ ? shelter . petFriendly
49
+ ? 'O abrigo aceita animais'
50
+ : 'O abrigo não aceita animais'
51
+ : 'Não informado se aceita animais'
54
52
}
55
53
/>
56
54
< InfoRow
You can’t perform that action at this time.
0 commit comments