added error checking, auto format check via link