Compare commits

...
3 Commits
Author SHA1 Message Date
Maksim Eltyshev e01a2eafba fix: Fix crash when uploading attachment 2022-06-24 17:17:42 +02:00
Maksim Eltyshev 3b3bff1b6b fix: Allow to use endpoints via http 2022-06-24 11:59:04 +02:00
Maksim Eltyshev ecc45c7a9e chore: Update version 2022-06-22 18:19:34 +02:00
4 changed files with 8 additions and 14 deletions
@@ -58,7 +58,7 @@ const Attachments = React.memo(
}, [toggleAllVisible]);
const galleryItemsNode = items.map((item, index) => {
const isPdf = item.url.endsWith('.pdf');
const isPdf = item.url && item.url.endsWith('.pdf');
let props;
if (item.image) {
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "planka",
"version": "1.3.0",
"version": "1.3.1",
"private": true,
"homepage": "https://plankanban.github.io/planka",
"repository": {
+3 -6
View File
@@ -33,11 +33,6 @@ module.exports = {
},
async fn(inputs) {
// TODO: allow over HTTP without subscription
if (!this.req.isSocket) {
return this.res.badRequest();
}
const { currentUser } = this.req;
const project = await Project.findOne(inputs.projectId);
@@ -61,7 +56,9 @@ module.exports = {
this.req,
);
sails.sockets.join(this.req, `board:${board.id}`); // TODO: only when subscription needed
if (this.req.isSocket) {
sails.sockets.join(this.req, `board:${board.id}`); // TODO: only when subscription needed
}
return {
item: board,
+3 -6
View File
@@ -20,11 +20,6 @@ module.exports = {
},
async fn(inputs) {
// TODO: allow over HTTP without subscription
if (!this.req.isSocket) {
return this.res.badRequest();
}
const { currentUser } = this.req;
const { board, project } = await sails.helpers.boards
@@ -77,7 +72,9 @@ module.exports = {
card.isSubscribed = isSubscribedByCardId[card.id] || false; // eslint-disable-line no-param-reassign
});
sails.sockets.join(this.req, `board:${board.id}`); // TODO: only when subscription needed
if (this.req.isSocket) {
sails.sockets.join(this.req, `board:${board.id}`); // TODO: only when subscription needed
}
return {
item: board,