MOBILE-3025 blocks: Fix comments block link
This commit is contained in:
parent
0724235a06
commit
0e9d0356af
@ -47,7 +47,7 @@ export class AddonBlockCommentsHandler extends CoreBlockBaseHandler {
|
||||
component: CoreBlockOnlyTitleComponent,
|
||||
link: 'CoreCommentsViewerPage',
|
||||
linkParams: { contextLevel: contextLevel, instanceId: instanceId,
|
||||
component: 'block_comments', area: 'page_comments', itemId: 0 }
|
||||
componentName: 'block_comments', area: 'page_comments', itemId: 0 }
|
||||
};
|
||||
}
|
||||
}
|
||||
|
@ -156,7 +156,7 @@ export class CoreCommentsViewerPage implements OnDestroy {
|
||||
this.canAddComments = this.addDeleteCommentsAvailable && response.canpost;
|
||||
|
||||
const comments = response.comments.sort((a, b) => b.timecreated - a.timecreated);
|
||||
this.canLoadMore = comments.length >= CoreCommentsProvider.pageSize;
|
||||
this.canLoadMore = comments.length > 0 && comments.length >= CoreCommentsProvider.pageSize;
|
||||
|
||||
return Promise.all(comments.map((comment) => {
|
||||
// Get the user profile image.
|
||||
|
Loading…
x
Reference in New Issue
Block a user