Fix struct order
Slight refactoring and addition of utils
Fix case
Remove unused import