Fixed 3.1.2 deprication issue