Fix subdomain, add test, space and comment fix

Cleaning things when learning the code.