code with common things for WW