Corrected the notices in constants not declared for all types of documents