Skip to content

Commit

Permalink
Merge branch 'development'
Browse files Browse the repository at this point in the history
  • Loading branch information
lmajano committed Jan 20, 2021
2 parents 1b48e1f + 048147c commit 3ebecaa
Show file tree
Hide file tree
Showing 7 changed files with 40 additions and 1,232 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

.artifacts/**
.tmp/**
modules/**

test-harness/.engine/**
test-harness/coldbox/**
Expand Down
11 changes: 7 additions & 4 deletions box.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name":"ColdBox i18n and Localization",
"author":"Ortus Solutions <info@ortussolutions.com>",
"version":"2.0.0",
"version":"2.1.0",
"location":"https://downloads.ortussolutions.com/ortussolutions/coldbox-modules/cbi18n/@build.version@/cbi18n-@build.version@.zip",
"slug":"cbi18n",
"type":"modules",
Expand All @@ -22,9 +22,12 @@
"contributors":[
"Brad Wood <bdw429s@gmail.com>",
"Curt Gratz <gratz@computerknowhow.com>",
"Jon Clausen <jon_clausen@silowebworks.com>",
"Wil de Bruin <wil@site4u.nl>"
],
"Jon Clausen <jon_clausen@silowebworks.com>",
"Wil de Bruin <wil@site4u.nl>"
],
"dependencies":{
"cbstorages":"^2.4.0+64"
},
"ignore":[
"**/.*",
"tests/*",
Expand Down
11 changes: 11 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

----

## [2.1.0] => 2021-JAN-20

### Fixed

* Missing `cbStorages` dependency on the `box.json` causes failures upon installation

### Added

* Added a shortcut compatiblity layer so v1 apps don't crash on choosing `localeStorage`. Basically, we map the incoming locale storage from the old approach: `session,client,cookie,request` to the `cbStorages` equivalent

----
## [2.0.0] => 2021-JAN-19

### Added
Expand Down
20 changes: 20 additions & 0 deletions models/i18n.cfc
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,26 @@ component singleton accessors="true" {
variables.defaultResourceBundle = variables.settings.defaultResourceBundle;
variables.defaultLocale = variables.settings.defaultLocale;

// v1 Shim for localestorage, remove by v3
switch( variables.localeStorage ){
case "session" : {
variables.localeStorage = "sessionStorage@cbstorages";
break;
}
case "client" : {
variables.localeStorage = "clientStorage@cbstorages";
break;
}
case "cookie" : {
variables.localeStorage = "cookieStorage@cbstorages";
break;
}
case "request" : {
variables.localeStorage = "requestStorage@cbstorages";
break;
}
}

// instantiate storage service for locale storage
try {
variables.storageService = variables.wirebox.getInstance( variables.localeStorage );
Expand Down
2 changes: 1 addition & 1 deletion test-harness/box.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"description":"",
"dependencies":{
"coldbox":"^6.0.0",
"cbstorages":"^2.2.0+50"
"cbstorages":"^2.4.0+64"
},
"devDependencies":{
"testbox":"^4.0.0"
Expand Down
1,224 changes: 0 additions & 1,224 deletions test-harness/hs_err_pid3189.log

This file was deleted.

3 changes: 0 additions & 3 deletions test-harness/server-server-lucee@5.json

This file was deleted.

0 comments on commit 3ebecaa

Please sign in to comment.