catching errors
formatting