mirror of
https://github.com/tooot-app/app
synced 2025-01-03 13:10:23 +01:00
Fix crash
This commit is contained in:
parent
c698ba84e6
commit
3238f44867
@ -20,6 +20,8 @@ export const CardNeodb: React.FC<Props> = ({ card }) => {
|
|||||||
if (!segments || !(segments[0] === 'movie' || segments[0] === 'book' || segments[0] === 'tv'))
|
if (!segments || !(segments[0] === 'movie' || segments[0] === 'book' || segments[0] === 'tv'))
|
||||||
return null
|
return null
|
||||||
|
|
||||||
|
const [headingLines, setHeadingLines] = useState(3)
|
||||||
|
|
||||||
const { data } = useNeodbQuery({ path: `${segments[0]}/${segments[1]}` })
|
const { data } = useNeodbQuery({ path: `${segments[0]}/${segments[1]}` })
|
||||||
|
|
||||||
if (!data) return null
|
if (!data) return null
|
||||||
@ -36,8 +38,6 @@ export const CardNeodb: React.FC<Props> = ({ card }) => {
|
|||||||
}
|
}
|
||||||
const contentProps = { style: { flex: 1, gap: StyleConstants.Spacing.S } }
|
const contentProps = { style: { flex: 1, gap: StyleConstants.Spacing.S } }
|
||||||
|
|
||||||
const [headingLines, setHeadingLines] = useState(3)
|
|
||||||
|
|
||||||
const itemImage = data.cover_image_url ? (
|
const itemImage = data.cover_image_url ? (
|
||||||
<GracefullyImage
|
<GracefullyImage
|
||||||
sources={{ default: { uri: data.cover_image_url } }}
|
sources={{ default: { uri: data.cover_image_url } }}
|
||||||
|
Loading…
Reference in New Issue
Block a user