tangled
alpha
login
or
join now
opencourse.world
/
ocw-server
0
fork
atom
The server for Open Course World
0
fork
atom
overview
issues
pulls
pipelines
add logging to course tag update errors
jneen
5 months ago
e4901893
6adedf5b
+8
-1
1 changed file
expand all
collapse all
unified
split
nex
datastore
datastore_smm2_server.go
+8
-1
nex/datastore/datastore_smm2_server.go
reviewed
···
6
6
"bytes"
7
7
"fmt"
8
8
"smm2_gameserver/nex/rmc"
9
9
+
"log"
9
10
)
10
11
11
12
type DataStoreServerSMM2 struct {
···
1912
1913
func (s *DataStoreServerSMM2) HandleUpdateCourseTag(r *bytes.Reader, w *bytes.Buffer) error {
1913
1914
var param UpdateCourseTagParam
1914
1915
if err := Decode(r, ¶m); err != nil {
1916
1916
+
log.Printf("Failed to parse course tag param: %w", err)
1915
1917
return err
1916
1918
}
1917
1919
···
1919
1921
return fmt.Errorf("Function not attached: func (s *YourServer) UpdateCourseTag(param datastore.UpdateCourseTagParam) (error) { return err }")
1920
1922
}
1921
1923
// Typedef: func(param datastore.UpdateCourseTagParam) (error) { return err }
1922
1922
-
return s.UpdateCourseTag(param)
1924
1924
+
if err := s.UpdateCourseTag(param); err != nil {
1925
1925
+
log.Printf("Failed to update course tag: %w", err)
1926
1926
+
return err
1927
1927
+
}
1928
1928
+
1929
1929
+
return nil
1923
1930
}
1924
1931
1925
1932
func (s *DataStoreServerSMM2) HandleGetCourses(r *bytes.Reader, w *bytes.Buffer) error {