Skip to content

Commit 9cc69b6

Browse files
committed
Pass the proper key to update the order status. It works!
1 parent 6fa885d commit 9cc69b6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

WooCommerce/Classes/ViewRelated/Orders/OrderStatusListViewController.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,14 +143,14 @@ extension OrderStatusListViewController {
143143
}
144144

145145
@objc func applyButtonTapped() {
146-
guard let newStatusName = selectedStatus?.name else {
146+
guard let newStatus = selectedStatus?.status.rawValue else {
147147
return
148148
}
149149

150150
let orderID = order.orderID
151151
let undoStatus = order.statusKey
152152

153-
let done = updateOrderAction(siteID: order.siteID, orderID: orderID, statusKey: newStatusName)
153+
let done = updateOrderAction(siteID: order.siteID, orderID: orderID, statusKey: newStatus)
154154
let undo = updateOrderAction(siteID: order.siteID, orderID: orderID, statusKey: undoStatus)
155155

156156
StoresManager.shared.dispatch(done)

0 commit comments

Comments
 (0)