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

Fixed try-catching #22

Closed
wants to merge 1 commit into from
Closed

Fixed try-catching #22

wants to merge 1 commit into from

Conversation

St1lk3r
Copy link
Contributor

@St1lk3r St1lk3r commented Aug 19, 2024

No description provided.

@@ -42,7 +42,7 @@ class GetPost final : public userver::server::handlers::HttpHandlerBase {
try {
post_id = boost::lexical_cast<boost::uuids::uuid>(post_id_as_text);
}
catch (std::bad_cast) {
catch (const std::bad_cast& ex) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Не обязательно чтобы оно было названо, если ты его используешь

Достаточно const std::bad_cast&

@St1lk3r St1lk3r closed this Aug 28, 2024
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