recreating my fork and adding setupmapifneeded method to the digfragment class