fix: linter issues
This commit is contained in:
@@ -85,7 +85,7 @@ describe('WorkspaceApiService', () => {
|
|||||||
it('should invite to a workspace', async () => {
|
it('should invite to a workspace', async () => {
|
||||||
const response = await createService().inviteToWorkspace({
|
const response = await createService().inviteToWorkspace({
|
||||||
workspaceUuid: 'w-1-2-3',
|
workspaceUuid: 'w-1-2-3',
|
||||||
inviteeEmail: 'test@test.te'
|
inviteeEmail: 'test@test.te',
|
||||||
})
|
})
|
||||||
|
|
||||||
expect(response).toEqual({
|
expect(response).toEqual({
|
||||||
@@ -95,7 +95,7 @@ describe('WorkspaceApiService', () => {
|
|||||||
})
|
})
|
||||||
expect(workspaceServer.inviteToWorkspace).toHaveBeenCalledWith({
|
expect(workspaceServer.inviteToWorkspace).toHaveBeenCalledWith({
|
||||||
workspaceUuid: 'w-1-2-3',
|
workspaceUuid: 'w-1-2-3',
|
||||||
inviteeEmail: 'test@test.te'
|
inviteeEmail: 'test@test.te',
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -109,7 +109,7 @@ describe('WorkspaceApiService', () => {
|
|||||||
try {
|
try {
|
||||||
await service.inviteToWorkspace({
|
await service.inviteToWorkspace({
|
||||||
workspaceUuid: 'w-1-2-3',
|
workspaceUuid: 'w-1-2-3',
|
||||||
inviteeEmail: 'test@test.te'
|
inviteeEmail: 'test@test.te',
|
||||||
})
|
})
|
||||||
} catch (caughtError) {
|
} catch (caughtError) {
|
||||||
error = caughtError
|
error = caughtError
|
||||||
@@ -127,7 +127,7 @@ describe('WorkspaceApiService', () => {
|
|||||||
try {
|
try {
|
||||||
await createService().inviteToWorkspace({
|
await createService().inviteToWorkspace({
|
||||||
workspaceUuid: 'w-1-2-3',
|
workspaceUuid: 'w-1-2-3',
|
||||||
inviteeEmail: 'test@test.te'
|
inviteeEmail: 'test@test.te',
|
||||||
})
|
})
|
||||||
} catch (caughtError) {
|
} catch (caughtError) {
|
||||||
error = caughtError
|
error = caughtError
|
||||||
|
|||||||
@@ -39,7 +39,7 @@ export class WorkspaceApiService implements WorkspaceApiServiceInterface {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async createWorkspace(dto: {
|
async createWorkspace(dto: {
|
||||||
workspaceType: WorkspaceType,
|
workspaceType: WorkspaceType
|
||||||
encryptedWorkspaceKey?: string
|
encryptedWorkspaceKey?: string
|
||||||
encryptedPrivateKey?: string
|
encryptedPrivateKey?: string
|
||||||
publicKey?: string
|
publicKey?: string
|
||||||
|
|||||||
@@ -10,8 +10,5 @@ export interface WorkspaceApiServiceInterface {
|
|||||||
publicKey?: string
|
publicKey?: string
|
||||||
workspaceName?: string
|
workspaceName?: string
|
||||||
}): Promise<WorkspaceCreationResponse>
|
}): Promise<WorkspaceCreationResponse>
|
||||||
inviteToWorkspace(dto: {
|
inviteToWorkspace(dto: { inviteeEmail: string; workspaceUuid: Uuid }): Promise<WorkspaceInvitationResponse>
|
||||||
inviteeEmail: string
|
|
||||||
workspaceUuid: Uuid
|
|
||||||
}): Promise<WorkspaceInvitationResponse>
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { Uuid } from "@standardnotes/common"
|
import { Uuid } from '@standardnotes/common'
|
||||||
|
|
||||||
export type WorkspaceInvitationRequestParams = {
|
export type WorkspaceInvitationRequestParams = {
|
||||||
workspaceUuid: Uuid
|
workspaceUuid: Uuid
|
||||||
|
|||||||
@@ -8,8 +8,5 @@ export interface WorkspaceClientInterface {
|
|||||||
publicKey?: string
|
publicKey?: string
|
||||||
workspaceName?: string
|
workspaceName?: string
|
||||||
}): Promise<{ uuid: string } | null>
|
}): Promise<{ uuid: string } | null>
|
||||||
inviteToWorkspace(dto: {
|
inviteToWorkspace(dto: { inviteeEmail: string; workspaceUuid: Uuid }): Promise<{ uuid: string } | null>
|
||||||
inviteeEmail: string
|
|
||||||
workspaceUuid: Uuid
|
|
||||||
}): Promise<{ uuid: string } | null>
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ export class WorkspaceManager extends AbstractService implements WorkspaceClient
|
|||||||
}
|
}
|
||||||
|
|
||||||
async createWorkspace(dto: {
|
async createWorkspace(dto: {
|
||||||
workspaceType: WorkspaceType,
|
workspaceType: WorkspaceType
|
||||||
encryptedWorkspaceKey?: string
|
encryptedWorkspaceKey?: string
|
||||||
encryptedPrivateKey?: string
|
encryptedPrivateKey?: string
|
||||||
publicKey?: string
|
publicKey?: string
|
||||||
|
|||||||
Reference in New Issue
Block a user