From 4a01c8e94921d9ddcaf6d6dee0feca4d9c3655a2 Mon Sep 17 00:00:00 2001 From: xengineering Date: Tue, 15 Jun 2021 15:51:38 +0200 Subject: Refactoring: Camera has Statemachine and not is Statemachine --- src/web.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/web.go') diff --git a/src/web.go b/src/web.go index 206681d..53f8c0a 100644 --- a/src/web.go +++ b/src/web.go @@ -58,11 +58,11 @@ func jsHandler(w http.ResponseWriter, r *http.Request) { func stateHandler(w http.ResponseWriter, r *http.Request) { known_state := r.FormValue("known_state") - w.Write([]byte(fmt.Sprintf("%s", camera.GetStateOnChange(known_state)))) + w.Write([]byte(fmt.Sprintf("%s", camera.statemachine.GetStateOnChange(known_state)))) } func singlePictureHandler(w http.ResponseWriter, r *http.Request) { - camera.SendEvent("take_single_picture") + camera.statemachine.SendEvent("take_single_picture") fmt.Fprintf(w, http.StatusText(http.StatusOK)) } -- cgit v1.2.3-70-g09d2