fixed version checking for 4.0 and higher