Simplified the if/else logic in the getter
This commit is contained in:
parent
6ddf0f29fb
commit
e7a04804b4
|
@ -29,11 +29,7 @@ final class SidebarExpandedContainers: ObservableObject {
|
|||
|
||||
subscript(_ containerID: ContainerIdentifier) -> Bool {
|
||||
get {
|
||||
if expandedTable.contains(containerID) {
|
||||
return true
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
return expandedTable.contains(containerID)
|
||||
}
|
||||
set(newValue) {
|
||||
if newValue {
|
||||
|
|
Loading…
Reference in New Issue