Just added some info to the profile as an example.

This commit is contained in:
Nathan Byrd 2023-01-01 11:07:33 -06:00
parent e1b4c3e510
commit db652bff59
1 changed files with 12 additions and 2 deletions

View File

@ -7,6 +7,7 @@ const { WellKnownLocations } = require('../web');
const _ = require('lodash'); const _ = require('lodash');
const User = require('../../../user'); const User = require('../../../user');
const UserProps = require('../../../user_property');
const Log = require('../../../logger').log; const Log = require('../../../logger').log;
exports.moduleInfo = { exports.moduleInfo = {
@ -110,9 +111,18 @@ exports.getModule = class WebFingerServerModule extends WebHandlerModule {
} }
// TODO: More user information here // TODO: More user information here
const body = ` let body = `
User name: ${user.username}, User information for: ${user.username}
Real name: ${user.getProperty(UserProps.RealName)},
Login Count: ${user.getProperty(UserProps.LoginCount)},
Affiliations: ${user.getProperty(UserProps.Affiliations)}`;
if (user.getProperty(UserProps.AchievementTotalPoints) > 0) {
body = body + `,
Total Points: ${user.getProperty(UserProps.AchievementTotalPoints)}
`; `;
}
const headers = { const headers = {
'Content-Type': 'text/plain', 'Content-Type': 'text/plain',