diff options
| author | 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> | 2025-01-15 00:35:41 +1100 |
|---|---|---|
| committer | 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> | 2025-01-15 00:35:41 +1100 |
| commit | 4ce74c4dc5302fdd7b33441c2f5999d458c58dab (patch) | |
| tree | 0a05896a8b02b6ad5a97f2e36b27a771be00b241 /modules | |
| parent | notifpopups: replace notifications (diff) | |
| download | caelestia-shell-4ce74c4dc5302fdd7b33441c2f5999d458c58dab.tar.gz caelestia-shell-4ce74c4dc5302fdd7b33441c2f5999d458c58dab.tar.bz2 caelestia-shell-4ce74c4dc5302fdd7b33441c2f5999d458c58dab.zip | |
bar: fix null pointer errors
Diffstat (limited to 'modules')
| -rw-r--r-- | modules/bar.tsx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/modules/bar.tsx b/modules/bar.tsx index dd576c3..9801f13 100644 --- a/modules/bar.tsx +++ b/modules/bar.tsx @@ -51,12 +51,14 @@ const ActiveWindow = () => ( className="icon" setup={self => hookFocusedClientProp(self, "class", c => { - self.label = c ? getAppCategoryIcon(c.class) : "desktop_windows"; + self.label = c?.class ? getAppCategoryIcon(c.class) : "desktop_windows"; }) } /> <label - setup={self => hookFocusedClientProp(self, "title", c => (self.label = c ? ellipsize(c.title) : "Desktop"))} + setup={self => + hookFocusedClientProp(self, "title", c => (self.label = c?.title ? ellipsize(c.title) : "Desktop")) + } /> </box> ); |