Skip to content

Commit

Permalink
Version 4.3.6
Browse files Browse the repository at this point in the history
  • Loading branch information
Simplify committed Nov 26, 2023
1 parent 12cbd05 commit d93c751
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
3 changes: 3 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
2023-10-14 Saša Jovanić <[email protected]>
* Version 4.3.6

2023-11-13 Davide Bianco <[email protected]>
* Fixed specs for Slovenian IBAN

Expand Down
2 changes: 1 addition & 1 deletion dist/ibantools.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ define(["require", "exports"], function (require, exports) {
* @package Documentation
* @author Saša Jovanić
* @module ibantools
* @version 4.3.5
* @version 4.3.6
* @license MPL-2.0
* @preferred
*/
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ibantools",
"version": "4.3.5",
"version": "4.3.6",
"description": "Validation, extraction and creation of IBAN, BBAN, BIC/SWIFT numbers plus some other helpful stuff like ISO 3136-1 alpha 2 country list",
"keywords": [
"IBAN",
Expand Down
10 changes: 5 additions & 5 deletions src/ibantools.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
* @package Documentation
* @author Saša Jovanić
* @module ibantools
* @version 4.3.5
* @version 4.3.6
* @license MPL-2.0
* @preferred
*/
Expand Down Expand Up @@ -290,19 +290,19 @@ export function extractIBAN(iban: string): ExtractIBANResult {
const ac = spec.account_indentifier.split('-');
const starting = parseInt(ac[0]);
const ending = parseInt(ac[1]);
result.accountNumber = result.iban.slice(starting, ending+1);
result.accountNumber = result.iban.slice(starting, ending + 1);
}
if (spec.bank_identifier) {
const ac = spec.bank_identifier.split('-');
const starting = parseInt(ac[0]);
const ending = parseInt(ac[1]);
result.bankIdentifier = result.bban.slice(starting, ending+1);
result.bankIdentifier = result.bban.slice(starting, ending + 1);
}
if (spec.branch_indentifier) {
const ac = spec.branch_indentifier.split('-');
const starting = parseInt(ac[0]);
const ending = parseInt(ac[1]);
result.branchIdentifier = result.bban.slice(starting, ending+1);
result.branchIdentifier = result.bban.slice(starting, ending + 1);
}
} else {
result.valid = false;
Expand Down Expand Up @@ -408,7 +408,7 @@ function replaceCharaterWithCode(str: string): string {
// https://jsbench.me/ttkzgsekae/1
return str
.split('')
.map((c) => {
.map(c => {
const code = c.charCodeAt(0);
return code >= 65 ? (code - 55).toString() : c;
})
Expand Down

0 comments on commit d93c751

Please sign in to comment.