summaryrefslogtreecommitdiff
path: root/resources/js/classes
diff options
context:
space:
mode:
authorDaniel Weipert <code@drogueronin.de>2023-08-24 14:42:12 +0200
committerDaniel Weipert <code@drogueronin.de>2023-08-24 14:42:12 +0200
commitbde5dc98ad96546b59e91f5a6e552bf80cbf48e4 (patch)
tree37196f5b5065c61ac038ae43d6f2392e29e39371 /resources/js/classes
parent7b1c251fcb085dc37de439ea1137373f1905d82e (diff)
translations and error handling
Diffstat (limited to 'resources/js/classes')
-rw-r--r--resources/js/classes/Area.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/resources/js/classes/Area.js b/resources/js/classes/Area.js
index e8d7acc..f518f22 100644
--- a/resources/js/classes/Area.js
+++ b/resources/js/classes/Area.js
@@ -12,7 +12,11 @@ class Area {
async initialize () {}
get name () {
- return DB.areas[this.slug].name;
+ return translate(this.alternateSlug) || slugToName(this.slug);
+ }
+
+ get alternateSlug () {
+ return DB.areas[this.slug]['modules/tuxemon.slug'];
}
get encounters () {