fix trigger function way references