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

Fomorian/Razorback construction and Events #125

Merged
merged 16 commits into from
Sep 20, 2017

Conversation

TobiTenno
Copy link
Member

No description provided.

@TobiTenno TobiTenno added the Status: In Progress Work has Begun label Sep 19, 2017
@TobiTenno TobiTenno changed the title adding embeds Fomorian/Razorback construction and Events Sep 19, 2017

this.color = 0xff6961;
this.fields = [{
name: `[${platform}] Construction Status:`,

Choose a reason for hiding this comment

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

Expected indentation of 6 spaces but found 8. (indent)

this.color = 0xff6961;
this.fields = [{
name: `[${platform}] Construction Status:`,
value: '```' +

Choose a reason for hiding this comment

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

Expected indentation of 6 spaces but found 8. (indent)

this.fields = [{
name: `[${platform}] Construction Status:`,
value: '```' +
`Razorback: ${construction.razorbackProgress}` +

Choose a reason for hiding this comment

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

'construction' is not defined. (no-undef)

name: `[${platform}] Construction Status:`,
value: '```' +
`Razorback: ${construction.razorbackProgress}` +
`Fomorian: ${construction.fomorianProgress}` +

Choose a reason for hiding this comment

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

'construction' is not defined. (no-undef)

value: '```' +
`Razorback: ${construction.razorbackProgress}` +
`Fomorian: ${construction.fomorianProgress}` +
`Unknown: ${construction.unknwonProgress}` +

Choose a reason for hiding this comment

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

'construction' is not defined. (no-undef)

`Razorback: ${construction.razorbackProgress}` +
`Fomorian: ${construction.fomorianProgress}` +
`Unknown: ${construction.unknwonProgress}` +
'```'

Choose a reason for hiding this comment

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

Missing trailing comma. (comma-dangle)

this.color = 0xfdec96;

if (event) {
this.title = `[${platform}] ${event.description}`;

Choose a reason for hiding this comment

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

Expected indentation of 6 spaces but found 8. (indent)


if (event) {
this.title = `[${platform}] ${event.description}`;
this.fields = [];

Choose a reason for hiding this comment

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

Expected indentation of 6 spaces but found 8. (indent)

this.title = `[${platform}] ${event.description}`;
this.fields = [];

if (event.victimNode) {

Choose a reason for hiding this comment

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

Expected indentation of 6 spaces but found 8. (indent)

this.fields = [];

if (event.victimNode) {
this.fields.push({name: '_ _', value: `Defend ${event.victimNode} by attacking the ${event.faction} at ${event.node}.` });

Choose a reason for hiding this comment

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

Expected indentation of 10 spaces but found 12. (indent)
A space is required after '{'. (object-curly-spacing)

if (event.victimNode) {
this.fields.push({name: '_ _', value: `Defend ${event.victimNode} by attacking the ${event.faction} at ${event.node}.` });
}
this.fields.push({ name: 'Rewards', value: event.rewards.map(reward => reward.asString).join('; ') });

Choose a reason for hiding this comment

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

Expected indentation of 6 spaces but found 8. (indent)

this.fields.push({name: '_ _', value: `Defend ${event.victimNode} by attacking the ${event.faction} at ${event.node}.` });
}
this.fields.push({ name: 'Rewards', value: event.rewards.map(reward => reward.asString).join('; ') });
this.fields.push({ name: 'Completion Score', value: String(event.maximumScore) });

Choose a reason for hiding this comment

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

Expected indentation of 6 spaces but found 8. (indent)

this.fields.push({ name: 'Rewards', value: event.rewards.map(reward => reward.asString).join('; ') });
this.fields.push({ name: 'Completion Score', value: String(event.maximumScore) });
} else {
this.title = 'No Current Events';

Choose a reason for hiding this comment

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

Expected indentation of 6 spaces but found 8. (indent)

const platformParam = message.strippedContent.match(this.regex)[1];
const platform = platformParam || await this.bot.settings.getChannelSetting(message.channel, 'platform');
const ws = await this.bot.caches[platform].getDataJson();
await this.messageManager.embed(message, new EventEmbed(this.bot, ws.constructionProgress, platform.toUpperCase()), true, true));

Choose a reason for hiding this comment

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

Parsing error: Unexpected token )

await Promise.all(results);
return this.messageManager.statuses.SUCCESS;
}
await this.messageManager.embed(message, new EventEmbed(this.bot, undefined, platform.toUpperCase()), true, true));

Choose a reason for hiding this comment

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

Parsing error: Unexpected token )

const platformParam = message.strippedContent.match(this.regex)[1];
const platform = platformParam || await this.bot.settings.getChannelSetting(message.channel, 'platform');
const ws = await this.bot.caches[platform].getDataJson();
await this.messageManager.embed(message, new EventEmbed(this.bot, ws.constructionProgress, platform.toUpperCase()), true, true);

Choose a reason for hiding this comment

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

Line 23 exceeds the maximum line length of 100. (max-len)

await Promise.all(results);
return this.messageManager.statuses.SUCCESS;
}
await this.messageManager.embed(message, new EventEmbed(this.bot, undefined, platform.toUpperCase()), true, true));

Choose a reason for hiding this comment

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

Parsing error: Unexpected token )

const platform = platformParam || await this.bot.settings.getChannelSetting(message.channel, 'platform');
const ws = await this.bot.caches[platform].getDataJson();
if (ws.events.length > 0) {
const results = [];

Choose a reason for hiding this comment

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

Expected indentation of 6 spaces but found 8. (indent)

const ws = await this.bot.caches[platform].getDataJson();
if (ws.events.length > 0) {
const results = [];
ws.events.forEach(event => {

Choose a reason for hiding this comment

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

Expected indentation of 6 spaces but found 8. (indent)
Expected parentheses around arrow function argument having a body with curly braces. (arrow-parens)

if (ws.events.length > 0) {
const results = [];
ws.events.forEach(event => {
results.push(this.messageManager.embed(message, new EventEmbed(this.bot, event, platform.toUpperCase()), true, true));

Choose a reason for hiding this comment

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

Line 26 exceeds the maximum line length of 100. (max-len)
Expected indentation of 10 spaces but found 12. (indent)

ws.events.forEach(event => {
results.push(this.messageManager.embed(message, new EventEmbed(this.bot, event, platform.toUpperCase()), true, true));
});
await Promise.all(results);

Choose a reason for hiding this comment

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

Expected indentation of 6 spaces but found 8. (indent)

results.push(this.messageManager.embed(message, new EventEmbed(this.bot, event, platform.toUpperCase()), true, true));
});
await Promise.all(results);
return this.messageManager.statuses.SUCCESS;

Choose a reason for hiding this comment

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

Expected indentation of 6 spaces but found 8. (indent)

await Promise.all(results);
return this.messageManager.statuses.SUCCESS;
}
await this.messageManager.embed(message, new EventEmbed(this.bot, undefined, platform.toUpperCase()), true, true);

Choose a reason for hiding this comment

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

Line 31 exceeds the maximum line length of 100. (max-len)

this.fields = [{
name: `[${platform}] Construction Status:`,
value: '```' +
`Razorback: ${construction.razorbackProgress}` +

Choose a reason for hiding this comment

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

'construction' is not defined. (no-undef)

name: `[${platform}] Construction Status:`,
value: '```' +
`Razorback: ${construction.razorbackProgress}` +
`Fomorian: ${construction.fomorianProgress}` +

Choose a reason for hiding this comment

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

'construction' is not defined. (no-undef)

value: '```' +
`Razorback: ${construction.razorbackProgress}` +
`Fomorian: ${construction.fomorianProgress}` +
`Unknown: ${construction.unknwonProgress}` +

Choose a reason for hiding this comment

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

'construction' is not defined. (no-undef)

`Razorback: ${construction.razorbackProgress}` +
`Fomorian: ${construction.fomorianProgress}` +
`Unknown: ${construction.unknwonProgress}` +
'```'

Choose a reason for hiding this comment

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

Missing trailing comma. (comma-dangle)

this.fields = [];

if (event.victimNode) {
this.fields.push({name: '_ _', value: `Defend ${event.victimNode} by attacking the ${event.faction} at ${event.node}.` });

Choose a reason for hiding this comment

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

Expected indentation of 8 spaces but found 10. (indent)
A space is required after '{'. (object-curly-spacing)

const ws = await this.bot.caches[platform].getDataJson();
if (ws.events.length > 0) {
const results = [];
ws.events.forEach(event => {

Choose a reason for hiding this comment

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

Expected parentheses around arrow function argument having a body with curly braces. (arrow-parens)

if (ws.events.length > 0) {
const results = [];
ws.events.forEach(event => {
results.push(this.messageManager.embed(message,

Choose a reason for hiding this comment

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

Expected indentation of 8 spaces but found 10. (indent)
Trailing spaces not allowed. (no-trailing-spaces)

await Promise.all(results);
return this.messageManager.statuses.SUCCESS;
}
await this.messageManager.embed(message, new EventEmbed(this.bot,

Choose a reason for hiding this comment

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

Trailing spaces not allowed. (no-trailing-spaces)

if (ws.events.length > 0) {
const results = [];
ws.events.forEach((event) => {
results.push(this.messageManager.embed(message,

Choose a reason for hiding this comment

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

Expected indentation of 8 spaces but found 10. (indent)

this.fields = [];

if (event.victimNode) {
this.fields.push({ name: '_ _', value: `Defend ${event.victimNode}` +

Choose a reason for hiding this comment

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

Object properties must go on a new line if they aren't all on the same line. (object-property-newline)

@TobiTenno
Copy link
Member Author

gonna test these when i'm home before i give it the ol +1

@TobiTenno TobiTenno merged commit 04165a6 into master Sep 20, 2017
@TobiTenno TobiTenno removed the Status: In Progress Work has Begun label Sep 20, 2017
@TobiTenno TobiTenno deleted the aliasfalse/construction-and-events branch September 21, 2017 01:56
TobiTenno added a commit that referenced this pull request Sep 22, 2017
* adding embeds

* Add commands for previously added embeds

* fix bad parentheses

* fix parens

* fix indents

* fix indents

* fix comma and syntax (construction didn't exist)

* fix some indents and line length

* fix line length

* fix line length

* stickler fixes

* fix indentation

* fix indents

* Update EventEmbed.js

* add health to event

* add platform to notifications and commands

default trials to auto-delete
update raven
change some logic for pricecheck embeds
fix for event embed messup

fix reward map issue

fix bad news embed call

add type for prime access notifications


another of above for updates


test fix for set ping

Async fixes (#126)

* make fatals and errors not log twice, cleanup logger typedef

* add logging for notifier

* fix some missing awaits.

* cleanup some debugs

* slim down debug

* more debugs

* more

* hopeful fix, awaiting callback function

* better formatting, abstract out wiki search for image

* fix construction progress

* more formatting for construction embed
TobiTenno added a commit that referenced this pull request Sep 22, 2017
* adding embeds

* Add commands for previously added embeds

* fix bad parentheses

* fix parens

* fix indents

* fix indents

* fix comma and syntax (construction didn't exist)

* fix some indents and line length

* fix line length

* fix line length

* stickler fixes

* fix indentation

* fix indents

* Update EventEmbed.js

* add health to event

* add platform to notifications and commands

default trials to auto-delete
update raven
change some logic for pricecheck embeds
fix for event embed messup

fix reward map issue

fix bad news embed call

add type for prime access notifications


another of above for updates


test fix for set ping

Async fixes (#126)

* make fatals and errors not log twice, cleanup logger typedef

* add logging for notifier

* fix some missing awaits.

* cleanup some debugs

* slim down debug

* more debugs

* more

* hopeful fix, awaiting callback function

* better formatting, abstract out wiki search for image

* fix construction progress

* more formatting for construction embed

Fomorian/Razorback construction and Events (#125)

* adding embeds

* Add commands for previously added embeds

* fix bad parentheses

* fix parens

* fix indents

* fix indents

* fix comma and syntax (construction didn't exist)

* fix some indents and line length

* fix line length

* fix line length

* stickler fixes

* fix indentation

* fix indents

* Update EventEmbed.js

* add health to event

* add platform to notifications and commands

default trials to auto-delete
update raven
change some logic for pricecheck embeds
fix for event embed messup

fix reward map issue

fix bad news embed call

add type for prime access notifications


another of above for updates


test fix for set ping

Async fixes (#126)

* make fatals and errors not log twice, cleanup logger typedef

* add logging for notifier

* fix some missing awaits.

* cleanup some debugs

* slim down debug

* more debugs

* more

* hopeful fix, awaiting callback function

* better formatting, abstract out wiki search for image

* fix construction progress

* more formatting for construction embed

fix an await in a loop


Merge branch 'morefixes'
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