Skip to content

Commit 77ed5a8

Browse files
committed
Fix adding more than 10 custom commands
1 parent 554319f commit 77ed5a8

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

Core/Sources/HostApp/CustomCommandSettings/CustomCommand.swift

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import ComposableArchitecture
22
import Foundation
3+
import PlusFeatureFlag
34
import Preferences
45
import SwiftUI
56
import Toast
@@ -24,7 +25,9 @@ struct CustomCommandFeature: ReducerProtocol {
2425
Reduce { state, action in
2526
switch action {
2627
case .createNewCommand:
27-
if settings.customCommands.count >= 10 {
28+
if !isFeatureAvailable(\.unlimitedCustomCommands),
29+
settings.customCommands.count >= 10
30+
{
2831
toast("Upgrade to Plus to add more commands", .info)
2932
return .none
3033
}

0 commit comments

Comments
 (0)