Small improvement thanks to Josh