mirror of
https://github.com/shishantbiswas/bknd.git
synced 2026-03-17 12:56:05 +00:00
fix: set default admin_basepath and logo_return_path in constructor
Move default option values into the constructor parameter initializer to prevent them from being overwritten by the spread operator in `get options()`.
This commit is contained in:
@@ -35,7 +35,10 @@ export class AppReduced {
|
|||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
protected appJson: AppType,
|
protected appJson: AppType,
|
||||||
protected _options: BkndAdminOptions = {},
|
protected _options: BkndAdminOptions = {
|
||||||
|
admin_basepath: '',
|
||||||
|
logo_return_path: '/'
|
||||||
|
},
|
||||||
) {
|
) {
|
||||||
//console.log("received appjson", appJson);
|
//console.log("received appjson", appJson);
|
||||||
|
|
||||||
@@ -85,7 +88,6 @@ export class AppReduced {
|
|||||||
|
|
||||||
get options() {
|
get options() {
|
||||||
return {
|
return {
|
||||||
admin_basepath: "",
|
|
||||||
logo_return_path: "/",
|
logo_return_path: "/",
|
||||||
...this._options,
|
...this._options,
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user