Cleaned up code for restart and parameter listing function