added checks and json
eddited json
another commit I guess