Minor fixes for friendly audited events, and a new function for comparing app IDs.
This commit is contained in:
parent
b60013cbb8
commit
6cc96f39b1
|
@ -392,6 +392,16 @@ export async function getDevAppIDs() {
|
|||
return apps.filter((id: any) => isDevAppID(id))
|
||||
}
|
||||
|
||||
export function isSameAppID(
|
||||
appId1: string | undefined,
|
||||
appId2: string | undefined
|
||||
) {
|
||||
if (appId1 == undefined || appId2 == undefined) {
|
||||
return false
|
||||
}
|
||||
return getProdAppID(appId1) === getProdAppID(appId2)
|
||||
}
|
||||
|
||||
export async function dbExists(dbName: any) {
|
||||
return doWithDB(
|
||||
dbName,
|
||||
|
|
|
@ -35,5 +35,5 @@ export interface SearchAuditLogsResponse extends PaginationResponse {
|
|||
}
|
||||
|
||||
export interface DefinitionsAuditLogsResponse {
|
||||
events: typeof AuditedEventFriendlyName
|
||||
events: Record<string, string>
|
||||
}
|
||||
|
|
|
@ -197,7 +197,7 @@ export const AuditedEventFriendlyName: Record<Event, string | undefined> = {
|
|||
[Event.USER_PERMISSION_ADMIN_REMOVED]: `User "{{ email }}" admin role removed`,
|
||||
[Event.USER_PERMISSION_BUILDER_ASSIGNED]: `User "{{ email }}" builder role assigned`,
|
||||
[Event.USER_PERMISSION_BUILDER_REMOVED]: `User "{{ email }}" builder role removed`,
|
||||
[Event.USER_INVITED]: `User "{{ email }} invited`,
|
||||
[Event.USER_INVITED]: `User "{{ email }}" invited`,
|
||||
[Event.USER_INVITED_ACCEPTED]: `User "{{ email }}" accepted invite`,
|
||||
[Event.USER_PASSWORD_UPDATED]: `User "{{ email }}" password updated`,
|
||||
[Event.USER_PASSWORD_RESET_REQUESTED]: `User "{{ email }}" password reset requested`,
|
||||
|
|
Loading…
Reference in New Issue