SAKE: Log provided field info

This commit is contained in:
mkwcat 2024-02-05 03:21:41 -05:00
parent 241ae4894b
commit 4f9916e6b3
No known key found for this signature in database
GPG Key ID: 7A505679CE9E7AA9

View File

@ -242,6 +242,9 @@ func getMyRecords(moduleName string, profileId uint32, gameInfo common.GameInfo,
switch gameInfo.Name + "/" + request.TableID {
default:
logging.Error(moduleName, "Unknown table")
for _, field := range request.Fields.Fields {
logging.Info(moduleName, "Field:", aurora.Cyan(field))
}
return &errorResponse
case "mariokartwii/FriendInfo":
@ -281,6 +284,9 @@ func updateRecord(moduleName string, profileId uint32, gameInfo common.GameInfo,
switch gameInfo.Name + "/" + request.TableID {
default:
logging.Error(moduleName, "Unknown table")
for _, field := range request.Values.RecordFields {
logging.Info(moduleName, "Field:", aurora.Cyan(field.Name), "Type:", aurora.Cyan(field.Value.XMLName.Local), "Value:", aurora.Cyan(field.Value.Value.Value))
}
return &errorResponse
case "mariokartwii/FriendInfo":
@ -311,6 +317,9 @@ func searchForRecords(moduleName string, gameInfo common.GameInfo, request Stora
switch gameInfo.Name + "/" + request.TableID {
default:
logging.Error(moduleName, "Unknown table")
for _, field := range request.Fields.Fields {
logging.Info(moduleName, "Field:", aurora.Cyan(field))
}
return &errorResponse
case "mariokartwii/FriendInfo":
@ -327,8 +336,6 @@ func searchForRecords(moduleName string, gameInfo common.GameInfo, request Stora
return &errorResponse
}
// TODO: Check if the two are friends maybe
values = []map[string]StorageValue{
{
"ownerid": uintValue(uint32(ownerId)),