API change to improve performance