Added a check if a property actually exists where errors were getting thrown.