mirror of
https://github.com/nocodb/nocodb.git
synced 2026-04-30 22:36:49 +00:00
chore(nc-gui): remove as any typecasts wherever possible
This commit is contained in:
@@ -35,8 +35,7 @@ const loadBase = async () => {
|
||||
try {
|
||||
if (!project.value.id) return
|
||||
|
||||
// todo: response is missing roles in type
|
||||
const res = (await $api.project.sharedBaseGet(project.value.id)) as any
|
||||
const res = await $api.project.sharedBaseGet(project.value.id)
|
||||
|
||||
base = {
|
||||
uuid: res.uuid,
|
||||
@@ -52,10 +51,9 @@ const createShareBase = async (role = ShareBaseRole.Viewer) => {
|
||||
try {
|
||||
if (!project.value.id) return
|
||||
|
||||
// todo: return type void?
|
||||
const res = (await $api.project.sharedBaseUpdate(project.value.id, {
|
||||
const res = await $api.project.sharedBaseUpdate(project.value.id, {
|
||||
roles: role,
|
||||
})) as any
|
||||
})
|
||||
|
||||
base = res ?? {}
|
||||
base!.role = role
|
||||
|
||||
Reference in New Issue
Block a user