Browse Source

refactor(nocodb): adopt getList new format in MapViewColumn.ts

pull/5430/head
Wing-Kam Wong 1 year ago
parent
commit
224c5a37bd
  1. 6
      packages/nocodb/src/lib/models/MapViewColumn.ts

6
packages/nocodb/src/lib/models/MapViewColumn.ts

@ -67,10 +67,8 @@ export default class MapViewColumn {
await NocoCache.set(`${CacheScope.MAP_VIEW_COLUMN}:${fk_column_id}`, id);
// if cache is not present skip pushing it into the list to avoid unexpected behaviour
if (
(await NocoCache.getList(CacheScope.MAP_VIEW_COLUMN, [column.fk_view_id]))
?.length
)
const { list } = await NocoCache.getList(CacheScope.MAP_VIEW_COLUMN, [column.fk_view_id]);
if (list?.length)
await NocoCache.appendToList(
CacheScope.MAP_VIEW_COLUMN,
[column.fk_view_id],

Loading…
Cancel
Save