mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-19 00:41:43 +00:00
[wpilibc] Alert: Fix first alert in group not publishing data (#7711)
This commit is contained in:
@@ -87,9 +87,9 @@ class Alert::SendableAlerts : public nt::NTSendable,
|
||||
wpi::SendableRegistry::EnsureInitialized();
|
||||
static wpi::StringMap<Alert::SendableAlerts> groups;
|
||||
|
||||
auto [iter, exists] = groups.try_emplace(group);
|
||||
auto [iter, inserted] = groups.try_emplace(group);
|
||||
SendableAlerts& sendable = iter->second;
|
||||
if (!exists) {
|
||||
if (inserted) {
|
||||
frc::SmartDashboard::PutData(group, &iter->second);
|
||||
}
|
||||
return sendable;
|
||||
|
||||
Reference in New Issue
Block a user