Codereview fixes.

This commit is contained in:
Dermot Duffy
2022-05-01 22:40:29 -07:00
parent d733498445
commit 14fb1c65eb
2 changed files with 2 additions and 3 deletions
-1
View File
@@ -964,7 +964,6 @@ export class FrigateCard extends LitElement {
extra: thumbnail ? { thumb: thumbnail } : {},
});
} else if (action === 'stop') {
console.info('stopping');
this._hass?.callService('media_player', 'media_stop', {
entity_id: mediaPlayer,
});
+2 -2
View File
@@ -193,7 +193,7 @@ const frigateCardCameraSelectActionSchema = frigateCardCustomactionsBaseSchema.e
frigate_card_action: z.literal('camera_select'),
camera: z.string(),
});
const frigateCarMediaPlayerPlayActionSchema = frigateCardCustomactionsBaseSchema.extend({
const frigateCarMediaPlayerActionSchema = frigateCardCustomactionsBaseSchema.extend({
frigate_card_action: z.literal('media_player'),
media_player: z.string(),
media_player_action: z.enum(['play', 'stop']),
@@ -202,7 +202,7 @@ const frigateCarMediaPlayerPlayActionSchema = frigateCardCustomactionsBaseSchema
export const frigateCardCustomActionSchema = z.union([
frigateCardGeneralActionSchema,
frigateCardCameraSelectActionSchema,
frigateCarMediaPlayerPlayActionSchema,
frigateCarMediaPlayerActionSchema,
]);
export type FrigateCardCustomAction = z.infer<typeof frigateCardCustomActionSchema>;