MCPcopy Create free account
hub / github.com/bytebase/bytebase / revisionLink

Function revisionLink

frontend/src/utils/v1/revision.ts:13–21  ·  view source on GitHub ↗
(revision: Revision)

Source from the content-addressed store, hash-verified

11};
12
13export const revisionLink = (revision: Revision): string => {
14 const parts = revision.name.split("/revisions/");
15 if (parts.length !== 2) {
16 return "";
17 }
18 const { database } = extractDatabaseResourceName(revision.name);
19 const composedDatabase = getDatabaseByName(database);
20 return `${databaseV1Url(composedDatabase)}/revisions/${parts[1]}`;
21};
22
23export const getRevisionType = (type: Revision_Type): string => {
24 switch (type) {

Callers 1

DatabaseRevisionTableFunction · 0.90

Calls 3

getDatabaseByNameFunction · 0.90
databaseV1UrlFunction · 0.90

Tested by

no test coverage detected