Creating edit controller