File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
WooCommerce/Classes/ViewRelated/Products/Edit Product/Product Settings Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ enum ProductSettingsRows {
4040 }
4141
4242 /// If the status is private, the status cell becomes not editable.
43- if settings . status == . privateStatus {
43+ if isStatusPrivate ( ) {
4444 cell. accessoryType = . none
4545 cell. selectionStyle = . none
4646 cell. applyNonSelectableLabelsStyle ( )
@@ -57,7 +57,7 @@ enum ProductSettingsRows {
5757 func handleTap( sourceViewController: UIViewController , onCompletion: @escaping ( ProductSettings ) -> Void ) {
5858
5959 /// If the status is private, the cell doesn't trigger any action
60- guard settings . status != . privateStatus else {
60+ guard isStatusPrivate ( ) else {
6161 return
6262 }
6363
@@ -75,6 +75,11 @@ enum ProductSettingsRows {
7575 let reuseIdentifier : String = SettingTitleAndValueTableViewCell . reuseIdentifier
7676
7777 let cellTypes : [ UITableViewCell . Type ] = [ SettingTitleAndValueTableViewCell . self]
78+
79+ /// Utils
80+ func isStatusPrivate( ) -> Bool {
81+ return settings. status == . privateStatus
82+ }
7883 }
7984
8085 struct Visibility : ProductSettingsRowMediator {
You can’t perform that action at this time.
0 commit comments