I have now removed the warning type assertions.