Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions packages/transport/src/core/TransportCoreErrors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,10 @@ class Tokens {
}

class General {
public noIdentityFound() {
return new CoreError("error.transport.general.noIdentityFound", "No Identity was found and the identity creation is not enabled.");
}

public baseUrlNotSet() {
return new CoreError("error.transport.general.baseUrlNotSet", "The baseUrl was not set.");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ export class AccountController {
if (!availableIdentityDoc && !availableDeviceDoc) {
if (!deviceSharedSecret) {
if (!this.config.allowIdentityCreation) {
throw new TransportError("No Identity found and identity creation is not allowed.");
throw TransportCoreErrors.general.noIdentityFound();
}

// Identity creation
Expand Down