removed return -1 at check functions