From 15561338d557714c9d96304f3d30247991427ad5 Mon Sep 17 00:00:00 2001 From: Starlight220 <53231611+Starlight220@users.noreply.github.com> Date: Mon, 28 Nov 2022 23:44:37 +0200 Subject: [PATCH] [commands] Remove one more default command isFinished check (#4727) --- .../src/main/native/cpp/frc2/command/CommandScheduler.cpp | 4 ---- 1 file changed, 4 deletions(-) diff --git a/wpilibNewCommands/src/main/native/cpp/frc2/command/CommandScheduler.cpp b/wpilibNewCommands/src/main/native/cpp/frc2/command/CommandScheduler.cpp index 2a73713e3a..5f702efefd 100644 --- a/wpilibNewCommands/src/main/native/cpp/frc2/command/CommandScheduler.cpp +++ b/wpilibNewCommands/src/main/native/cpp/frc2/command/CommandScheduler.cpp @@ -302,10 +302,6 @@ void CommandScheduler::SetDefaultCommand(Subsystem* subsystem, throw FRC_MakeError(frc::err::CommandIllegalUse, "{}", "Default commands must require their subsystem!"); } - if (defaultCommand.get()->IsFinished()) { - throw FRC_MakeError(frc::err::CommandIllegalUse, "{}", - "Default commands should not end!"); - } SetDefaultCommandImpl(subsystem, std::move(defaultCommand).Unwrap()); }