Add some reflections and refactor