Showing 1 changed files with 2 additions and 2 deletions
+2 -2
analyse-votes-AN
... ...
@@ -682,8 +682,8 @@ if test "$periode" = $true_flag; then
682 682
     if test "$envoi_par_mail" = $true_flag; then
683 683
         texte_periode="du $(get_date ${periode_value%:*} first) (scrutin n°$first) au $(get_date ${periode_value#*:} last) (scrutin n°$last)"
684 684
     fi
685
-elif test "$dossier" != $true_flag; then
686
-    test -z "$last" && last=$(dernier_scrutin_public)
685
+elif test "$dossier" != $true_flag -a "$no_db_update" = $true_flag; then
686
+    test -z "$last" && last=$(sqlite_request "select max(num) from scrutins")
687 687
     test -z "$first" && first=1
688 688
 fi
689 689