modify when-changed to work like watch