getbasename fixed