Added a typecast to work around issue that the types did not match because of the use of an interface

Signed-off-by: Stefan Marr <git@stefan-marr.de>