Refactor as it originally was on http://www.solarma.it/