feature/6-mediawiki_integration
master
closes #6
@@ -263,3 +136,4 @@
robot.logger.debug(`[hubot-kredits] Proposal created (${proposal.description})`);
// messageRoom(`Let's give ${contributor.name} some kredits for ${proposal.url} (${proposal.description}): https://kredits.kosmos.org`);
});
👍
This branch works with GitHub now!
do we need a const util = require('util'); in this file?
const util = require('util');
Please ignore the code until I have pushed all of my changes. Thanks.
Correction: it works on my machine, but I have to push some more fixes, when I'm done.
All done! \o/
@@ -0,0 +21,4 @@
let contrib = contributors.find(c => {
if (typeof c.accounts !== 'object') { return false; }
return c.accounts.find(a => {
a.url === `${process.env.KREDITS_MEDIAWIKI_URL}User:${username}`;
do we need to do a toLowerCase or something to compare the usernames?
@@ -0,0 +25,4 @@
if (!contrib) {
throw new Error();
could provider an error message here, something like contributor not found ${username}
contributor not found ${username}
Ideally we have the correct usernames on the blockchain. I haven't looked into the MediaWiki specifics there.
we only have the usernames in the IPFS profile. which actually is fine because we want to store as little as possible in the contract
No dependencies set.
The note is not visible to the blocked user.
closes #6
@@ -263,3 +136,4 @@robot.logger.debug(`[hubot-kredits] Proposal created (${proposal.description})`);// messageRoom(`Let's give ${contributor.name} some kredits for ${proposal.url} (${proposal.description}): https://kredits.kosmos.org`);});});👍
This branch works with GitHub now!
do we need a
const util = require('util');in this file?Please ignore the code until I have pushed all of my changes. Thanks.
Correction: it works on my machine, but I have to push some more fixes, when I'm done.
All done! \o/
👍
@@ -0,0 +21,4 @@let contrib = contributors.find(c => {if (typeof c.accounts !== 'object') { return false; }return c.accounts.find(a => {a.url === `${process.env.KREDITS_MEDIAWIKI_URL}User:${username}`;do we need to do a toLowerCase or something to compare the usernames?
@@ -0,0 +25,4 @@});});if (!contrib) {throw new Error();could provider an error message here, something like
contributor not found ${username}@@ -0,0 +21,4 @@let contrib = contributors.find(c => {if (typeof c.accounts !== 'object') { return false; }return c.accounts.find(a => {a.url === `${process.env.KREDITS_MEDIAWIKI_URL}User:${username}`;Ideally we have the correct usernames on the blockchain. I haven't looked into the MediaWiki specifics there.
@@ -0,0 +21,4 @@let contrib = contributors.find(c => {if (typeof c.accounts !== 'object') { return false; }return c.accounts.find(a => {a.url === `${process.env.KREDITS_MEDIAWIKI_URL}User:${username}`;we only have the usernames in the IPFS profile. which actually is fine because we want to store as little as possible in the contract