How do I find where a ruby method is declared?

后端 未结 3 859
情深已故
情深已故 2020-12-29 09:40

I have a ruby method (deactivate!) that is on an activeRecord class. However, I can\'t seem to find where that method is declared.

There have been numerous develope

3条回答
  •  小鲜肉
    小鲜肉 (楼主)
    2020-12-29 10:08

    As a first stab, try the Jump to Declaration feature of your IDE. Depending on how good your IDE's static type inference is, it should take you right there.

    If that doesn't work, set a breakpoint on that call, fire up the debugger and step into the method.

提交回复
热议问题