Man Sentenced to 40 Years for Mosque Shooting