Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add !mtr command implementation #38

Merged
merged 4 commits into from
Jan 23, 2017
Merged

Add !mtr command implementation #38

merged 4 commits into from
Jan 23, 2017

Conversation

hgarus
Copy link
Contributor

@hgarus hgarus commented Jan 21, 2017

Solves #37 and #11

Copy link
Owner

@bra1n bra1n left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job, noticed only one minor issue.

const Table = require('tty-table');
const log = require('log4js').getLogger('mtr');

const IPG_ADDRESS = process.env.IPG_ADDRESS || 'https://sites.google.com/site/mtgfamiliar/rules/MagicTournamentRules-light.html';
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IPG_ADDRESS?

if (/Format Deck Construction$/.test(title)) {
// Asking a bot for the banlist has to be one of the worst ways to inquire about card legality that I can imagine,
// defer handling this until I'm really bored and redirect people to the annotated mtr in the meantime
return `You can find the full text of ${title} on <${this.location}${number.replace('.', '-')}>`;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Haha, very nice. 😁 👍

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Come to think of it, this is actually a separate issue: #18

@bra1n bra1n merged commit 1424136 into master Jan 23, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants