Fix for #23

- rewrirtten defaults values creation. It was overcomplicated and buggy.
- impemented correct JSON values detection in defaults.