Synchronization now working

There are minor changes too.