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

Born Mirei 🎉 #7

Merged
merged 2 commits into from
Jun 20, 2017
Merged

Born Mirei 🎉 #7

merged 2 commits into from
Jun 20, 2017

Conversation

mizukmb
Copy link
Owner

@mizukmb mizukmb commented Jun 20, 2017

closes: #1

ぷり


def find_regulation(number)
# OPTIMIZE: Yaml lazy load.
@regulation_list ||= YAML.load_file('../config/settings.yml')
Copy link
Owner Author

Choose a reason for hiding this comment

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

Can change to lazy load? 🤔

@regulation_list ||= YAML.load_file('../config/settings.yml')

# TODO: Error handling.
@regulation_list.dig('regulations', number)
Copy link
Owner Author

Choose a reason for hiding this comment

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

Cause Error NoMethodError: undefined method []' for nil:NilClass` at 14 line.

MUST be catch the error.

@mizukmb
Copy link
Owner Author

mizukmb commented Jun 20, 2017

LGTM ぷり

tumblr_nmzedh7ay91qbgi6oo1_500

@mizukmb mizukmb merged commit 74dddf8 into master Jun 20, 2017
@mizukmb mizukmb deleted the mirei branch June 20, 2017 15:39
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.

#1 アイドル始めちゃいました!
1 participant