Fix Power Loss Recovery file delete (#13522)

This commit is contained in:
Robby Candra
2019-03-31 01:14:58 +07:00
committed by Scott Lahteine
parent d992dfe7d5
commit a3f67acd6d
3 changed files with 4 additions and 3 deletions

View File

@ -1004,7 +1004,7 @@ void CardReader::printingHasFinished() {
#if ENABLED(POWER_LOSS_RECOVERY)
constexpr char job_recovery_file_name[4] = "BIN";
constexpr char job_recovery_file_name[4] = "PLR";
bool CardReader::jobRecoverFileExists() {
const bool exists = recovery.file.open(&root, job_recovery_file_name, O_READ);
@ -1026,7 +1026,6 @@ void CardReader::printingHasFinished() {
// be zeroed and written instead of deleted.
void CardReader::removeJobRecoveryFile() {
if (jobRecoverFileExists()) {
//closefile();
removeFile(job_recovery_file_name);
#if ENABLED(DEBUG_POWER_LOSS_RECOVERY)
SERIAL_ECHOPGM("Power-loss file delete");