custom twig filter to replace last occurence of dot in image