minor cleanup
parent
52d5fc859d
commit
55329bb4ae
|
@ -12,3 +12,4 @@ npm-debug.log
|
|||
shinobi.sqlite
|
||||
package-lock.json
|
||||
dist
|
||||
._*
|
||||
|
|
|
@ -175,7 +175,7 @@ module.exports = function(s,config,lang){
|
|||
){
|
||||
if(!user.lang){
|
||||
var details = s.parseJSON(user.details).lang
|
||||
user.lang = s.getDefinitonFile(user.details.lang) || s.copySystemDefaultLanguage()
|
||||
user.lang = s.getLanguageFile(user.details.lang) || s.copySystemDefaultLanguage()
|
||||
}
|
||||
onSuccessComplete(user)
|
||||
}else{
|
||||
|
|
|
@ -383,6 +383,35 @@ module.exports = async (s,config,lang,app,io) => {
|
|||
}
|
||||
},res,req)
|
||||
})
|
||||
// /**
|
||||
// * API : Superuser : Custom Auto Load Package Update.
|
||||
// */
|
||||
// app.post(config.webPaths.superApiPrefix+':auth/package/update', async (req,res) => {
|
||||
// s.superAuth(req.params, async (resp) => {
|
||||
// try{
|
||||
// const url = req.body.downloadUrl
|
||||
// const packageRoot = req.body.packageRoot || ''
|
||||
// const packageName = req.body.packageName || extractNameFromPackage(url)
|
||||
// const modulePath = getModulePath(packageName)
|
||||
// await downloadModule(url,packageName)
|
||||
// const properties = getModuleProperties(packageName)
|
||||
// const newName = await moveModuleToNameInProperties(modulePath,packageRoot,properties)
|
||||
// const chosenName = newName ? newName : packageName
|
||||
//
|
||||
// disableModule(chosenName,true)
|
||||
// s.closeJsonResponse(res,{
|
||||
// ok: true,
|
||||
// moduleName: chosenName,
|
||||
// newModule: getModule(chosenName)
|
||||
// })
|
||||
// }catch(err){
|
||||
// s.closeJsonResponse(res,{
|
||||
// ok: false,
|
||||
// error: err
|
||||
// })
|
||||
// }
|
||||
// },res,req)
|
||||
// })
|
||||
/**
|
||||
* API : Superuser : Custom Auto Load Package Install.
|
||||
*/
|
||||
|
|
Loading…
Reference in New Issue