added function to check for module component.