Fixed the status message, and straightened up the code a bit