mirror of
https://github.com/Unleash/unleash.git
synced 2025-01-25 00:07:47 +01:00
feat: update feature completed payload to have boolean instead of string (#7855)
For easy gitar integration, we need to have boolean in the event payload. We might rethink it when we add variants, but currently enabled with variants is not used.
This commit is contained in:
parent
17e2102f0e
commit
bbdb5e635b
@ -186,7 +186,7 @@ export class FeatureLifecycleService {
|
||||
new FeatureCompletedEvent({
|
||||
project: projectId,
|
||||
featureName: feature,
|
||||
data: status,
|
||||
data: { ...status, kept: status.status === 'kept' },
|
||||
auditUser,
|
||||
}),
|
||||
);
|
||||
|
@ -8,9 +8,9 @@ import type {
|
||||
} from './model';
|
||||
import type { IApiToken } from './models/api-token';
|
||||
import type { IAuditUser, IUserWithRootRole } from './user';
|
||||
import type { FeatureLifecycleCompletedSchema } from '../openapi';
|
||||
import type { ITagType } from '../features/tag-type/tag-type-store-type';
|
||||
import type { IFeatureAndTag } from './stores/feature-tag-store';
|
||||
import type { FeatureLifecycleCompletedSchema } from '../openapi';
|
||||
|
||||
export const APPLICATION_CREATED = 'application-created' as const;
|
||||
|
||||
@ -749,13 +749,13 @@ export class FeatureTagImport extends BaseEvent {
|
||||
|
||||
export class FeatureCompletedEvent extends BaseEvent {
|
||||
readonly featureName: string;
|
||||
readonly data: FeatureLifecycleCompletedSchema;
|
||||
readonly data: FeatureLifecycleCompletedSchema & { kept: boolean };
|
||||
readonly project: string;
|
||||
|
||||
constructor(p: {
|
||||
project: string;
|
||||
featureName: string;
|
||||
data: FeatureLifecycleCompletedSchema;
|
||||
data: FeatureLifecycleCompletedSchema & { kept: boolean };
|
||||
auditUser: IAuditUser;
|
||||
}) {
|
||||
super(FEATURE_COMPLETED, p.auditUser);
|
||||
|
Loading…
Reference in New Issue
Block a user