Fixed Issue #648,using local variable