mirror of https://github.com/halo-dev/halo
pref: replace == usage with equals to avoid bugs. (#851)
Co-authored-by: sebastiancoteanu <sebastian.coteanu@arnia.ro>pull/854/head
parent
ecc97c207f
commit
c3f777fba3
|
@ -106,7 +106,7 @@ public class ThemeServiceImpl implements ThemeService {
|
||||||
Executors.newSingleThreadScheduledExecutor().scheduleWithFixedDelay(() -> {
|
Executors.newSingleThreadScheduledExecutor().scheduleWithFixedDelay(() -> {
|
||||||
try {
|
try {
|
||||||
String newActivatedThemeId = optionService.getByPropertyOrDefault(PrimaryProperties.THEME, String.class, DEFAULT_THEME_ID);
|
String newActivatedThemeId = optionService.getByPropertyOrDefault(PrimaryProperties.THEME, String.class, DEFAULT_THEME_ID);
|
||||||
if (newActivatedThemeId != activatedThemeId) {
|
if (!activatedThemeId.equals(newActivatedThemeId)) {
|
||||||
activateTheme(newActivatedThemeId);
|
activateTheme(newActivatedThemeId);
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
|
|
Loading…
Reference in New Issue