changed the input type of respond function.