fix facebook build phase script
refactor sync photos. lazy init view mapping for subsets.