The flux through the surface is taken as positive if the flux lines are directed outwards and negative if the flux is directed inwards.