move hasCheckpoint in the initialization because it does file operations

Signed-off-by: Sébastien Boisvert <sebastien.boisvert.3@ulaval.ca>