refactor phash calculation and saving into one place.
fix general foo-bars
reverse some overwitting error
add new localise keys (equires localisation)
unify all pre-processor closing details