fix API version processing