---
title: "Comment by Serguei Cambour on \"Understanding Rails Callbacks & Common Pitfalls\" | Hashnode"
description: "Thank you so much for sharing such useful tips. One point: you have a tiny typo in Comapny.find_by!(name:...), - it should be Company, I suppose :). Also in the"
url: "https://hashnode.com/posts/understanding-rails-callbacks-common-pitfalls/654006edcf0027421c8ede20/comment/654611f831ab12d0f49f0a0c"
---

[Discussion](https://hashnode.com/posts/understanding-rails-callbacks-common-pitfalls/654006edcf0027421c8ede20)

Comment [Understanding Rails Callbacks & Common Pitfalls](https://hashnode.com/posts/understanding-rails-callbacks-common-pitfalls/654006edcf0027421c8ede20)

[Serguei Cambour](https://hashnode.com/@belgoros)

[Nov 4, 2023](https://hashnode.com/posts/understanding-rails-callbacks-common-pitfalls/654006edcf0027421c8ede20/comment/654611f831ab12d0f49f0a0c)

Thank you so much for sharing such useful tips. One point: you have a tiny typo in Comapny.find\_by!(name:...), - it should be Company, I suppose :).

Also in the `Brake#do_brake` method, I don't think the call `puts "Brake id: #{self.brake.id}"` to correct, - you are calling `brake` on the instance of the `Brake` class instead of just calling `id` method.
