Added wait and wait-for-change function