Update class to be compatible with SDK v 5.0.1