Skip to content

Commit

Permalink
fix for the too many query generated by too many table_exists? calls …
Browse files Browse the repository at this point in the history
…[#836 state:resolved]
  • Loading branch information
ddnexus committed Oct 27, 2010
1 parent 01d11f8 commit 8eb0547
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions hobo/lib/hobo/model.rb
Expand Up @@ -333,6 +333,11 @@ def view_hints
class_name.safe_constantize or Object.class_eval("class #{class_name} < Hobo::ViewHints; end; #{class_name}")
end

def table_exists?
@table_exists_cache = super if @table_exists_cache.nil?
@table_exists_cache
end


end # --- of ClassMethods --- #

Expand Down

0 comments on commit 8eb0547

Please sign in to comment.