more logic fixing.