Files
XMBOX/apk_extracted/assets/js/lib/http.js
T
您的名字 dab1425dea 🐛 Fix source switching crash & enhance stability (v3.0.4)
### 🐛 Bug Fixes
- Fix random crashes when switching video sources in settings management
- Enhanced VodConfig.setHome() null pointer exception handling
- Improved Fragment lifecycle checks to prevent crashes
- Optimized HistoryDialog source switching safety
- Enhanced thread safety for concurrent loading

###  Performance Improvements
- Added automatic cache cleaning functionality
- Improved memory usage optimization
- Enhanced network request stability

### 🆕 New Features
- Added comprehensive error handling mechanisms
- Enhanced crash protection functionality
- Improved Fragment state validation

### 📱 Build Improvements
- Updated README with professional documentation
- Enhanced build configuration for ARM64-V8A and ARM V7A
- Improved APK packaging and signing process
2025-07-30 21:25:10 +08:00

17 lines
469 B
JavaScript

let req = (url, options) => http(url, Object.assign({
async: false
}, options));
function http(url, options = {}) {
if (options?.async === false) return _http(url, options)
return new Promise(resolve => _http(url, Object.assign({
complete: res => resolve(res)
}, options))).catch(err => {
console.error(err.name, err.message, err.stack)
return {
ok: false,
status: 500,
url
}
})
}