Skip to content

Commit

Permalink
refactor: pdf preview plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
reruin committed Jun 8, 2020
1 parent c2c90af commit a5e5c83
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 387 deletions.
4 changes: 2 additions & 2 deletions app/controllers/sharelist.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ const output = async (ctx , data)=>{
delete query.preview
let querystr = qs.stringify(query)
let purl = ctx.path + ( querystr ? ('?' + querystr) : '')

await ctx.renderSkin('detail',{
data : re , displayDownloadLabel,
url : isProxy ? purl : url
Expand Down Expand Up @@ -154,7 +154,7 @@ module.exports = {
ctx.status = 404
}
else if(data.type == 'body' || data.body){
if( typeof data.body == 'object' ){
if( typeof data.body == 'object'){
ctx.body = data.body
}else{
await ctx.renderSkin('custom',{
Expand Down
Loading

0 comments on commit a5e5c83

Please sign in to comment.