Now using redux to not create sound player every time the phaser is also implicitely cached
This commit is contained in:
@@ -2,7 +2,7 @@ import Model, { ModelValidator } from './Model';
|
||||
import * as yup from 'yup';
|
||||
import ResponseHandler from './ResponseHandler';
|
||||
|
||||
export const SearchType = ['song', 'artist', 'album'] as const;
|
||||
export const SearchType = ['song', 'artist', 'album', 'genre'] as const;
|
||||
export type SearchType = (typeof SearchType)[number];
|
||||
|
||||
const SearchHistoryValidator = yup
|
||||
@@ -27,7 +27,7 @@ export const SearchHistoryHandler: ResponseHandler<
|
||||
|
||||
interface SearchHistory extends Model {
|
||||
query: string;
|
||||
type: 'song' | 'artist' | 'album' | 'genre';
|
||||
type: SearchType;
|
||||
userId: number;
|
||||
timestamp: Date;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user