修复each被多个if调用而引发的错误

Signed-off-by: Gaubee <Gaubeebangeel@gmail.com>