mirror of
https://gitee.com/mafgwo/stackedit
synced 2024-11-16 03:32:40 +08:00
Fixed pdf and pandoc export
This commit is contained in:
parent
87f281c700
commit
e76f28294b
|
@ -43,13 +43,15 @@ export default modalTemplate({
|
|||
const currentFile = this.$store.getters['file/current'];
|
||||
const currentContent = this.$store.getters['content/current'];
|
||||
const { selectedFormat } = this;
|
||||
const [sponsorToken, token] = await this.$store.dispatch('queue/enqueue', () => Promise.all([
|
||||
this.$store.dispatch('queue/enqueue', async () => {
|
||||
const [sponsorToken, token] = await Promise.all([
|
||||
Promise.resolve().then(() => {
|
||||
const tokenToRefresh = this.$store.getters['workspace/sponsorToken'];
|
||||
return tokenToRefresh && googleHelper.refreshToken(tokenToRefresh);
|
||||
}),
|
||||
sponsorSvc.getToken(),
|
||||
]));
|
||||
]);
|
||||
|
||||
try {
|
||||
const { body } = await networkSvc.request({
|
||||
method: 'POST',
|
||||
|
@ -74,6 +76,7 @@ export default modalTemplate({
|
|||
this.$store.dispatch('notification/error', err);
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
},
|
||||
});
|
||||
|
|
|
@ -36,8 +36,8 @@ export default modalTemplate({
|
|||
async resolve() {
|
||||
this.config.resolve();
|
||||
const currentFile = this.$store.getters['file/current'];
|
||||
const [sponsorToken, token, html] = await this.$store
|
||||
.dispatch('queue/enqueue', () => Promise.all([
|
||||
this.$store.dispatch('queue/enqueue', async () => {
|
||||
const [sponsorToken, token, html] = await Promise.all([
|
||||
Promise.resolve().then(() => {
|
||||
const tokenToRefresh = this.$store.getters['workspace/sponsorToken'];
|
||||
return tokenToRefresh && googleHelper.refreshToken(tokenToRefresh);
|
||||
|
@ -48,7 +48,8 @@ export default modalTemplate({
|
|||
this.allTemplatesById[this.selectedTemplate],
|
||||
true,
|
||||
),
|
||||
]));
|
||||
]);
|
||||
|
||||
try {
|
||||
const { body } = await networkSvc.request({
|
||||
method: 'POST',
|
||||
|
@ -71,6 +72,7 @@ export default modalTemplate({
|
|||
this.$store.dispatch('notification/error', err);
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
},
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue
Block a user