Updates to personalization
This commit is contained in:
@@ -32,6 +32,9 @@ function App() {
|
||||
const { data: themePlaylists, isFetched: isThemePlaylistsFetched } = useQueryAPI({
|
||||
endpoint: 'api/themePlaylists',
|
||||
});
|
||||
const { data: personalData, isFetched: isPersonalDataFetched } = useQueryAPI({
|
||||
endpoint: 'api/personalData',
|
||||
});
|
||||
const {
|
||||
theme,
|
||||
setTheme,
|
||||
@@ -78,7 +81,7 @@ function App() {
|
||||
);
|
||||
|
||||
useEffect(() => {
|
||||
if (allThemes && themeName) {
|
||||
if (allThemes && themeName && personalData) {
|
||||
if (currentThemePlaylist === 'All') {
|
||||
if (themeName === 'random') {
|
||||
handleThemeChange(allThemes, false);
|
||||
@@ -124,6 +127,7 @@ function App() {
|
||||
allThemes,
|
||||
currentThemePlaylist,
|
||||
isThemePlaylistsFetched,
|
||||
isPersonalDataFetched,
|
||||
]);
|
||||
return (
|
||||
<>
|
||||
|
||||
Reference in New Issue
Block a user