Skip to content

Commit

Permalink
fix(bluetooth_monitor): fix unreadVariable (#8371)
Browse files Browse the repository at this point in the history
fix:unreadVariable

Signed-off-by: kobayu858 <[email protected]>
  • Loading branch information
kobayu858 authored Aug 9, 2024
1 parent 0e54b7e commit fb2fc7d
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions system/bluetooth_monitor/src/bluetooth_monitor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,6 @@ void BluetoothMonitor::setErrorLevel(diagnostic_updater::DiagnosticStatusWrapper
return;
}

int level = DiagStatus::OK;
int whole_level = DiagStatus::OK;
StatusCode whole_status_code = StatusCode::OK;
int index = 0;
Expand All @@ -158,7 +157,7 @@ void BluetoothMonitor::setErrorLevel(diagnostic_updater::DiagnosticStatusWrapper
stat.add(fmt::format("Device {}: {}", index, status.function_name), status.error_message);
}

level = status_error_list_.at(status.status_code);
int level = status_error_list_.at(status.status_code);
whole_level = std::max(whole_level, level);
whole_status_code = std::max(whole_status_code, status.status_code);
++index;
Expand Down

0 comments on commit fb2fc7d

Please sign in to comment.