replacing checks with standarized utilities.  example for other top-level scripts.