Update hooks to new format