Check if schema attribute is set before using it