Fixed variable names. Made variables in Sync private. Fixed tabbing.