coninued to work on posts error handling and flash messaging