minor fixes to fitting