implemented hook