From b161dcadfd38964682ab7094332fa635231aa935 Mon Sep 17 00:00:00 2001 From: Miles Date: Sun, 10 Dec 2023 23:37:28 -0500 Subject: [PATCH] Update docstring --- src/qn/flux.jl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/qn/flux.jl b/src/qn/flux.jl index 08fd97b497..5eb2c83f0b 100644 --- a/src/qn/flux.jl +++ b/src/qn/flux.jl @@ -68,10 +68,11 @@ allfluxequal(T::Tensor) = allequal(flux(T, b) for b in nzblocks(T)) Check that fluxes of all non-zero blocks of a blocked or symmetric Tensor are equal. Throws an error if one or more blocks have a different flux. +If the tensor is dense (is not blocked) then `checkflux` returns `nothing`. """ -function checkflux(T::Tensor) +function checkflux(T::Tensor) (!hasqns(T) || isempty(T)) && return nothing - allfluxequal(T) ? nothing : error("Fluxes not all equal") + return allfluxequal(T) ? nothing : error("Fluxes not all equal") end """