Some changes to sync and fix bugs in the prompt