Skip to content

A fully open source & end-to-end encrypted note taking alternative to Evernote.

fix pinned items not showing

ammarahm-edbc4a7b0fcb69
diff --git a/apps/mobile/src/components/SimpleList/index.js b/apps/mobile/src/components/SimpleList/index.js
index 2f36822cf..c6e4cc173 100644
--- a/apps/mobile/src/components/SimpleList/index.js
+++ b/apps/mobile/src/components/SimpleList/index.js
@@ -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' ? (
diff --git a/apps/mobile/src/views/Folders/index.js b/apps/mobile/src/views/Folders/index.js
index 625ea0ab6..44b5c1efc 100644
--- a/apps/mobile/src/views/Folders/index.js
+++ b/apps/mobile/src/views/Folders/index.js
@@ -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>
diff --git a/apps/mobile/src/views/Home/index.js b/apps/mobile/src/views/Home/index.js
index 8bb076c7a..d57ecd9e0 100755
--- a/apps/mobile/src/views/Home/index.js
+++ b/apps/mobile/src/views/Home/index.js
@@ -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}