Fixing error not None case
Fixing flux output in subpixel case