Compare commits

..

2 Commits

Author SHA1 Message Date
f69e343d89 1.2.4 2024-10-23 22:43:17 +02:00
7b29584afd Fixed profile merge breaking if no main profile is available. 2024-10-23 22:43:15 +02:00
3 changed files with 7 additions and 3 deletions

View File

@@ -126,6 +126,10 @@ async function fetchProfiles(actorIdsOrNames, { knex }) {
}
function mergeMainProfile(profile, mainProfile) {
if (!mainProfile) {
return profile;
}
const preservedKeys = ['id'];
const mergedProfile = Object.fromEntries(Object.entries(profile).map(([key, value]) => [key, mainProfile[key] === null || preservedKeys.includes(key)

4
package-lock.json generated
View File

@@ -1,12 +1,12 @@
{
"name": "traxxx-utils",
"version": "1.2.3",
"version": "1.2.4",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "traxxx-utils",
"version": "1.2.3",
"version": "1.2.4",
"license": "ISC",
"devDependencies": {
"@babel/cli": "^7.25.7",

View File

@@ -1,6 +1,6 @@
{
"name": "traxxx-common",
"version": "1.2.3",
"version": "1.2.4",
"description": "Common utilities for traxxx core and web.",
"main": "src/app.js",
"scripts": {