Fix stub deprecation