Fixed a bug when introducing the get_schema function