1
0
Fork 1
mirror of https://github.com/pixelfed/pixelfed.git synced 2024-12-25 09:17:03 +00:00

Update app.js

This commit is contained in:
Daniel Supernault 2019-12-05 20:57:00 -07:00
parent 39acd99b73
commit d3a37a0030
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7

View file

@ -33,6 +33,32 @@ window.App.boot = function() {
}
window.App.util = {
compose: {
post: (function() {
let path = window.location.pathname;
let whitelist = [
'/',
'/timeline/public'
];
if(whitelist.includes(path)) {
$('#composeModal').modal('show');
} else {
window.location.href = '/?a=co';
}
}),
circle: (function() {
console.log('Unsupported method.');
}),
collection: (function() {
console.log('Unsupported method.');
}),
loop: (function() {
console.log('Unsupported method.');
}),
story: (function() {
console.log('Unsupported method.');
}),
},
time: (function() {
return new Date;
}),