diff --git a/src/RegToken.c b/src/RegToken.c index a5aa123..3f8f66d 100644 --- a/src/RegToken.c +++ b/src/RegToken.c @@ -210,6 +210,8 @@ RegTokenJSON(RegTokenInfo * info) return NULL; } + /* TODO: Consider adding the tokinfo property into + * the RegTokenInfo struct to make that easier. */ tokinfo.name = info->name; tokinfo.created_on = info->created; tokinfo.expires_on = info->expires; @@ -224,13 +226,7 @@ RegTokenJSON(RegTokenInfo * info) * to -1 */ tokinfo.uses = info->uses; } - if (!(tokinfo.created_by = info->owner)) - { - /* The owner can be null if Telodendria created it. - * Since users can't contain a space, it is in this case set to - * "Telodendria Server". */ - tokinfo.created_by = "Telodendria Server"; - } + tokinfo.created_by = info->owner; return TokenInfoToJson(&tokinfo);