fixed image broken fot twitter, refactoring