Improved the properties reading.