MCPcopy Create free account
hub / github.com/badyun/AShare / get

Function get

controller/fileS.js:5–25  ·  view source on GitHub ↗
(req, res)

Source from the content-addressed store, hash-verified

3module.exports = {
4 list: {
5 async get(req, res) {
6
7 if (!req.query.user_id) {
8 return res.error("阿里云账号不存在")
9 }
10 let info = db('account').find({ user_id: req.query.user_id }).value()
11 if (!info) {
12 return res.error("阿里云账号不存在")
13 }
14
15 const cloud = new Cloud(info.id)
16
17 try {
18 let list = await cloud.list(req.query.parent_file_id)
19 res.return(list)
20 } catch (error) {
21 // console.log(error)
22 res.error(error)
23 }
24
25 }
26 },
27 previewVideo: {
28 async get(req, res) {

Callers

nothing calls this directly

Calls 2

listMethod · 0.80
previewVideoMethod · 0.80

Tested by

no test coverage detected