Fixed minor bug on 2.1+ backport