Attempt at fixing reflection - there is still a bug