# Urgent help needed! "uninitialized constant" error

**URL:** <https://www.ruby-forum.com/t/urgent-help-needed-uninitialized-constant-error/133925>\
**Category:** Rails\
**Created:** [April 5, 2008, 1:23am UTC](https://www.ruby-forum.com/t/urgent-help-needed-uninitialized-constant-error/133925 "2008-04-05T01:23:23Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![nasir](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/n/3bc359/32.png) [@nasir](https://www.ruby-forum.com/u/nasir)\
**Post date:** [April 5, 2008, 1:23am UTC](https://www.ruby-forum.com/t/urgent-help-needed-uninitialized-constant-error/133925/1 "2008-04-05T01:23:23Z")

</div>

I need a hint on what could be causing the following error message:

NameError in Project areasController#destroy  
uninitialized constant ProjectArea::KeyAspect  
D:/Ruby/ruby/lib/ruby/gems/1.8/gems/activesupport-1.4.2/lib/active\_support/dependencies.rb:477:in  
`const_missingâ€™ (eval):1:in`configure\_dependency\_for\_has\_manyâ€™  
#{RAILS\_ROOT}/app/controllers/project\_areas\_controller.rb:129:in  
`destroyâ€™ script\server:3 -e:2:in`loadâ€™  
-e:2

Many thanks people

---

<div class="post-metadata">

**Author:** ![nasir](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/n/3bc359/32.png) [@nasir](https://www.ruby-forum.com/u/nasir)\
**Post date:** [April 5, 2008, 6:57pm UTC](https://www.ruby-forum.com/t/urgent-help-needed-uninitialized-constant-error/133925/2 "2008-04-05T18:57:31Z")

</div>

There’s not enough information here. I’d say it probably lies in the  
ProjectArea model. My guess would be that you have a has\_many  
association that looks like this:

has\_many :KeyAspects

instead of

has\_many :key\_aspects?

On Apr 4, 7:23 pm, Nasir J. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)
