From e85c19adcb71149922332150d45d671f90bd1f9f Mon Sep 17 00:00:00 2001 From: Narr the Reg Date: Mon, 3 Oct 2022 18:06:55 -0500 Subject: service: nfp: Fix errors to pass unit testing --- src/core/hid/emulated_controller.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/core/hid/emulated_controller.cpp') diff --git a/src/core/hid/emulated_controller.cpp b/src/core/hid/emulated_controller.cpp index e27d84734..025f1c78e 100644 --- a/src/core/hid/emulated_controller.cpp +++ b/src/core/hid/emulated_controller.cpp @@ -1017,9 +1017,11 @@ bool EmulatedController::SetPollingMode(Common::Input::PollingMode polling_mode) auto& output_device = output_devices[static_cast(DeviceIndex::Right)]; auto& nfc_output_device = output_devices[3]; - nfc_output_device->SetPollingMode(polling_mode); + const auto virtual_nfc_result = nfc_output_device->SetPollingMode(polling_mode); + const auto mapped_nfc_result = output_device->SetPollingMode(polling_mode); - return output_device->SetPollingMode(polling_mode) == Common::Input::PollingError::None; + return virtual_nfc_result == Common::Input::PollingError::None || + mapped_nfc_result == Common::Input::PollingError::None; } bool EmulatedController::SetCameraFormat( -- cgit v1.2.3