diff options
author | crupest <crupest@outlook.com> | 2021-01-09 23:44:45 +0800 |
---|---|---|
committer | crupest <crupest@outlook.com> | 2021-01-09 23:44:45 +0800 |
commit | cbf7990a2fed00db64a683d9691f96eb2623193e (patch) | |
tree | 11de2e4e896a9426a528450666f1608dbf30e339 /FrontEnd/src/app/views/timeline-common/TimelinePageTemplate.tsx | |
parent | 8b0f3472b3023fb62126be90575259aae23eda79 (diff) | |
download | timeline-cbf7990a2fed00db64a683d9691f96eb2623193e.tar.gz timeline-cbf7990a2fed00db64a683d9691f96eb2623193e.tar.bz2 timeline-cbf7990a2fed00db64a683d9691f96eb2623193e.zip |
...
Diffstat (limited to 'FrontEnd/src/app/views/timeline-common/TimelinePageTemplate.tsx')
-rw-r--r-- | FrontEnd/src/app/views/timeline-common/TimelinePageTemplate.tsx | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/FrontEnd/src/app/views/timeline-common/TimelinePageTemplate.tsx b/FrontEnd/src/app/views/timeline-common/TimelinePageTemplate.tsx index 35b31ec2..f66d14e0 100644 --- a/FrontEnd/src/app/views/timeline-common/TimelinePageTemplate.tsx +++ b/FrontEnd/src/app/views/timeline-common/TimelinePageTemplate.tsx @@ -110,7 +110,7 @@ export default function TimelinePageTemplate<TManageItem>( : undefined, })); - const others = { + const operations = { onPost: service.hasPostPermission(user, timeline) ? onPost : undefined, @@ -189,20 +189,20 @@ export default function TimelinePageTemplate<TManageItem>( }; if (type === "cache") { - return [{ timeline, posts, ...others }, "syncing"]; + return [{ timeline, posts, operations }, "syncing"]; } else if (type === "offline") { - return [{ timeline, posts, ...others }, "offline"]; + return [{ timeline, posts, operations }, "offline"]; } else { if (postListState == null) { - return [{ timeline, posts, ...others }, "syncing"]; + return [{ timeline, posts, operations }, "syncing"]; } else { const { type: postListType } = postListState; if (postListType === "synced") { - return [{ timeline, posts, ...others }, "synced"]; + return [{ timeline, posts, operations }, "synced"]; } else if (postListType === "cache") { - return [{ timeline, posts, ...others }, "syncing"]; + return [{ timeline, posts, operations }, "syncing"]; } else if (postListType === "offline") { - return [{ timeline, posts, ...others }, "offline"]; + return [{ timeline, posts, operations }, "offline"]; } } } |