From d154e1e37b026679fc76c6708f6b16951ed07dd9 Mon Sep 17 00:00:00 2001 From: MikunoNaka Date: Sun, 13 Jun 2021 23:56:43 +0530 Subject: minor bug fix --- server/database/people.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'server') diff --git a/server/database/people.go b/server/database/people.go index e0930b0..ac2affa 100644 --- a/server/database/people.go +++ b/server/database/people.go @@ -23,7 +23,7 @@ type Person struct { func GetAllPeople() []Person { var allPeople []Person rows, _ := myDatabase.Query( - `SELECT id, Name, Phone, Email FROM People`, + `SELECT Name, Address, Phone, Email FROM People`, ) var ( @@ -39,11 +39,10 @@ func GetAllPeople() []Person { } func RegisterPerson(person Person) bool { - register_person, _ := myDatabase.Prepare( `INSERT INTO People (Name, Address, Phone, Email) - VALUES (?, ?, ?)`, + VALUES (?, ?, ?, ?)`, ) register_person.Exec( -- cgit v1.2.3