dialog work. singletons re-implemented