Good idea. I think this should be async, though, so a plugin can use stuff from the database here (and db queries need to be async).