Hopefully fixed reflection code