save context after sync