Improved utils.