From 5261327ccfe94a712c1898fe21469d6872e9aee4 Mon Sep 17 00:00:00 2001
From: Dario Barghini <dario.barghini@inaf.it>
Date: Wed, 20 Nov 2024 22:19:34 +0100
Subject: [PATCH] Fix bug on report_year after return codes refactoring

---
 code/calibration/report_year.pro | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/code/calibration/report_year.pro b/code/calibration/report_year.pro
index 6238a20..1dfc611 100644
--- a/code/calibration/report_year.pro
+++ b/code/calibration/report_year.pro
@@ -27,7 +27,12 @@ endif
 
 ; reading camera parameters structure from last analyzed month
 par = get_par(config, camera, ff[-1], /return0)
-if par.file eq '' then return
+if par.file eq '' then begin
+  
+  cd, old_dir
+  return
+
+endif
 
 ; checking for keyword input
 if isa(report_calib) then par.config.calibration.report_calib = report_calib
-- 
GitLab