Added  checking for module exists