code cleanup, watcher first version