-added helper functions to update puzzle db