Add a proper type for |callback| and add a comment for this function.