Resolved deprecated warning