Skip to content

Commit

Permalink
more 0.6.1
Browse files Browse the repository at this point in the history
  • Loading branch information
crash1115 committed Jun 17, 2021
1 parent dafdf6d commit 202881d
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 17 deletions.
2 changes: 1 addition & 1 deletion changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Version 0.6.1
- Compatibility with Foundry 0.8.6
- Compatibility with Foundry 0.8.7
- Fixed logic that determines which users can perform migrations on which actors. Asst / GM's should be able to do all actors now, and Trusted/Players should be able to do the ones they own.

# Version 0.6.0 (Foundry 0.8.x)
Expand Down
17 changes: 4 additions & 13 deletions module.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,13 @@
"title": "Crash's Tracking & Training (5e)",
"description": "Adds a section to the character sheet to keep track of downtime activities, training, spell scribing, faction reputation, quest progress, and anything else you can think of.",
"author": "CRASH1115#2944",
"authors": [],
"url": "https://github.com/crash1115/5e-training",
"readme": "https://github.com/crash1115/5e-training/blob/master/README.md",
"bugs": "https://github.com/crash1115/5e-training/issues",
"flags": {},
"version": "0.6.1",
"minimumCoreVersion": "0.8.2",
"compatibleCoreVersion": "0.8.6",
"scripts": [],
"compatibleCoreVersion": "0.8.7",
"minimumSystemVersion": "1.3.0",
"esmodules": [
"scripts/crash-5e-training.js"
],
Expand Down Expand Up @@ -43,13 +41,6 @@
"path": "lang/es.json"
}
],
"packs": [],
"system": [],
"dependencies": [],
"socket": false,
"manifest": "https://raw.githubusercontent.com/crash1115/5e-training/master/module.json",
"download": "https://github.com/crash1115/5e-training/releases/download/v0.6.0/5e-training.zip",
"protected": false,
"coreTranslation": false,
"minimumSystemVersion": "1.3.0"
}
"download": "https://github.com/crash1115/5e-training/releases/download/v0.6.1/5e-training.zip"
}
6 changes: 3 additions & 3 deletions scripts/crash-5e-training.js
Original file line number Diff line number Diff line change
Expand Up @@ -236,8 +236,8 @@ async function migrateAllActors(){
// If the user can't update the actor, skip it
let currentUserId = game.userId;
let currentUserOwnsActor = a.data.permission[currentUserId] === 3;
let currentUserCanUpdate = game.user.role >= 3;
if(!currentUserOwnsActor && !currentUserCanUpdate){
let currentUserIsGm = game.user.isGM;
if(!currentUserOwnsActor && !currentUserIsGm){
// console.log("Crash's Tracking & Training (5e): " + game.i18n.localize("C5ETRAINING.Skipping") + ": " + a.data.name);
continue;
}
Expand All @@ -251,7 +251,7 @@ async function migrateAllActors(){
allTrainingItems[j].updateMe = true;
allTrainingItems[j].schemaVersion = 0;
itemsToUpdate++;
} else if(allTrainingItems[j].SchemVersion < LATEST_MIGRATION){ // If the latest is newer, gotta update
} else if(allTrainingItems[j].schemaVersion < LATEST_MIGRATION){ // If the latest is newer, gotta update
allTrainingItems[j] = true;
itemsToUpdate++;
}
Expand Down

0 comments on commit 202881d

Please sign in to comment.