fixed control for snapshots
Merge pull request #1025 from LorenzoBoccaccia/fix-build

fixed control for snapshots