Added new utility function