fix pinned items not showing

This commit is contained in:
ammarahm-ed
2020-04-22 11:22:20 +05:00
parent 6134ec842a
commit bc4a7b0fcb
3 changed files with 4 additions and 4 deletions

View File

@@ -127,10 +127,10 @@ const SimpleList = ({
? 155 - insets.top
: 155 - 60 - insets.top,
}}>
{pinned && pinned.notebooks && pinned.notebooks.length > 0 ? (
{pinned && pinned.length > 0 ? (
<>
<FlatList
data={pinned.notebooks}
data={pinned}
keyExtractor={(item, index) => item.id.toString()}
renderItem={({item, index}) =>
item.type === 'notebook' ? (

View File

@@ -141,7 +141,7 @@ export const Folders = ({navigation}) => {
<NotebookPlaceHolder animation={slideRight} colors={colors} />
</>
}
pinned={pinned}
pinned={pinned.notebooks}
placeholderText="Notebooks you add will appear here"
/>
</Container>

View File

@@ -115,7 +115,7 @@ export const Home = ({navigation}) => {
data={notes}
type="notes"
isHome={true}
pinned={pinned}
pinned={pinned.notes}
refreshing={refreshing}
focused={isFocused}
onRefresh={_onRefresh}