Change snapshot manager to remove the empty directories

Change-Id: I4c7fd7c7bb56241adfd53cfd3f923ee858bbdb5c
Merge "Change snapshot manager to remove the empty directories"