some small fixups in main
adding older version of the file