Fix warnings
Rearrange classes