From 39fe77fa31c85099795bc295fb29c506a3eb5878 Mon Sep 17 00:00:00 2001
From: Alex Reisner <alex@alexreisner.com>
Date: Mon, 26 Nov 2012 10:22:31 -0600
Subject: [PATCH] Add Troubleshooting section.

Document uninitialized constant error with Mongoid.
---
 README.md | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/README.md b/README.md
index a6657865..cc2ac092 100644
--- a/README.md
+++ b/README.md
@@ -590,6 +590,17 @@ You can also do this to raise all exceptions:
 See `lib/geocoder/exceptions.rb` for a list of raise-able exceptions.
 
 
+Troubleshooting
+---------------
+
+If you get one of these errors:
+
+    uninitialized constant Geocoder::Model::Mongoid
+    uninitialized constant Geocoder::Model::Mongoid::Mongo
+
+you should check your Gemfile to make sure the Mongoid gem is listed _before_ Geocoder. If Mongoid isn't loaded when Geocoder is initialized, Geocoder will not load support for Mongoid.
+
+
 Known Issue
 -----------
 
-- 
GitLab