temporarily solving #42 in a ugly way. Ready to refactor some code