Skip to content

Commit

Permalink
Remove unused code path in Admin UI (#6592)
Browse files Browse the repository at this point in the history
  • Loading branch information
timleslie authored Sep 17, 2021
1 parent 8bbba49 commit 273ee44
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
5 changes: 5 additions & 0 deletions .changeset/healthy-cougars-tickle.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@keystone-next/keystone': patch
---

Removed check for access denied on count operations in the Admin UI databoard queries, as these errors are no longer returned.
Original file line number Diff line number Diff line change
Expand Up @@ -182,11 +182,6 @@ export const HomePage = () => {
return null;
}
const result = dataGetter.get(key);
// TODO: Checking based on the message is bad, but we need to revisit GraphQL errors in
// Keystone to fix it and that's a whole other can of worms...
if (result.errors?.[0].message === 'You do not have access to this resource') {
return <ListCard count={{ type: 'no-access' }} key={key} listKey={key} />;
}
return (
<ListCard
count={
Expand Down

0 comments on commit 273ee44

Please sign in to comment.