Fix backend to support posting image files