Fix problem when handling STI: it will now interpret the corresponding "type" column properly in remote classes