Fixed PHP warnings in generateSnapshots() methods