Fix for state checking
Add type validators for layer properties