From 5e03282bd0536ca5dc0ab8007a508c1e0fa3a312 Mon Sep 17 00:00:00 2001 From: Abhishek Banthia <8280282+n0shake@users.noreply.github.com> Date: Sun, 31 Mar 2024 16:13:46 -0400 Subject: [PATCH] Return early if place in menubar is selected --- Clocker/Panel/Data Layer/TimezoneDataOperations.swift | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Clocker/Panel/Data Layer/TimezoneDataOperations.swift b/Clocker/Panel/Data Layer/TimezoneDataOperations.swift index 32fa726..2b60548 100644 --- a/Clocker/Panel/Data Layer/TimezoneDataOperations.swift +++ b/Clocker/Panel/Data Layer/TimezoneDataOperations.swift @@ -83,9 +83,13 @@ extension TimezoneDataOperations { func compactMenuTitle() -> String { var subtitle = CLEmptyString - let shouldDayBeShown = store.shouldShowDayInMenubar() let shouldLabelBeShownAlongWithTime = !store.shouldDisplay(.placeInMenubar) - + + if shouldLabelBeShownAlongWithTime == false { + return dataObject.formattedTimezoneLabel() + } + + let shouldDayBeShown = store.shouldShowDayInMenubar() if shouldDayBeShown, shouldLabelBeShownAlongWithTime { let substring = date(with: 0, displayType: .menu) subtitle.append(substring)