tidied up and fixed errors in nano.d