Skip to content

Commit

Permalink
fix wrong splithttp default (MHSanaei#2433)
Browse files Browse the repository at this point in the history
This default is defined as 1MB, but maxUploadSize is to be specified in
bytes. This confusion could've come from poorly written documentation in
xray, but it has been updated.

in general I wish that panels would not set defaults at all and instead
just omit parameters (in sharelinks, inbounds, ...) that the user didn't
set explicitly. If I want to change the defaults in xray's codebase, it
seems that all the panels will have to update the default too.

I see marzban doing the same kind of things.
  • Loading branch information
mmmray authored and aircross committed Jul 10, 2024
1 parent 95a9495 commit 974e68c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions web/assets/js/model/xray.js
Original file line number Diff line number Diff line change
Expand Up @@ -523,7 +523,7 @@ class HTTPUpgradeStreamSettings extends XrayCommonClass {
}

class SplitHTTPStreamSettings extends XrayCommonClass {
constructor(path='/', host='', headers=[] , maxUploadSize= 1, maxConcurrentUploads= 10) {
constructor(path='/', host='', headers=[] , maxUploadSize= 1000000, maxConcurrentUploads= 10) {
super();
this.path = path;
this.host = host;
Expand Down Expand Up @@ -2608,4 +2608,4 @@ Inbound.WireguardSettings.Peer = class extends XrayCommonClass {
keepAlive: this.keepAlive?? undefined,
};
}
};
};

0 comments on commit 974e68c

Please sign in to comment.