Skip to content

Instantly share code, notes, and snippets.

@oasisfeng
Created September 7, 2021 15:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save oasisfeng/a3cd5b54a0dcc14a046e0b59d585fc86 to your computer and use it in GitHub Desktop.
Save oasisfeng/a3cd5b54a0dcc14a046e0b59d585fc86 to your computer and use it in GitHub Desktop.
// ==UserScript==
// @name Baidu Netdisk Mobile Tweaks
// @namespace http://tampermonkey.net/
// @version 0.1
// @description Some tweaks to Baidu Netdisk Mobile Web.
// @author Oasis Feng
// @match https://pan.baidu.com/disk/home*
// @grant none
// ==/UserScript==
(function() {
'use strict';
(function(open) {
XMLHttpRequest.prototype.open = function() {
if (arguments.length > 1 && arguments[1].startsWith('/api/list?')) // Sort by name
arguments[1] = arguments[1].replace('desc=1', 'desc=0').replace('order=time', 'order=name')
open.apply(this, arguments);
};
})(XMLHttpRequest.prototype.open);
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment