quite a few changes, main one is validation