Fix some missing class convertion

that were not tester by the way.. I'll try to add some tests for that