Revert "Stringify $pin for validate_re call"

This reverts commit 4bb0dbc9de129b825af60132bc0229a797a5b3bc.
use str2bool for condition