Added extra checks for the wireframe