Ugly client code improvement