Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Fix a few typos #240

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion django_mongodb_engine/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ def _value_for_db(self, value, field, field_kind, db_type, lookup):
"valid ObjectId string."
raise DatabaseError(msg)

# PyMongo can only process datatimes?
# PyMongo can only process datetimes?
elif db_type == 'date':
return datetime.datetime(value.year, value.month, value.day)
elif db_type == 'time':
Expand Down
2 changes: 1 addition & 1 deletion django_mongodb_engine/contrib/search/fields.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def get_db_prep_lookup(self, lookup_type, value, connection,
value = ''.join(value)

# When 'exact' is used we'll perform an exact_phrase query
# using the $all operator otherwhise we'll just tokenized
# using the $all operator otherwise we'll just tokenized
# the value. Djangotoolbox will do the remaining checks.
if lookup_type == 'exact':
return {'$all': self._tokenizer.tokenize(value)}
Expand Down
2 changes: 1 addition & 1 deletion django_mongodb_engine/fields.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ def pre_save(self, model_instance, add):

def _on_pre_delete(self, sender, instance, using, signal, **kwargs):
"""
Deletes the files associated with this isntance.
Deletes the files associated with this instance.

If versioning is enabled all versions will be deleted.
"""
Expand Down
2 changes: 1 addition & 1 deletion django_mongodb_engine/storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class GridFSStorage(Storage):
This backend aims to add a GridFS storage to upload files to
using Django's file fields.

For performance, the file hirarchy is represented as a tree of
For performance, the file hierarchy is represented as a tree of
MongoDB sub-collections.

(One could use a flat list, but to list a directory '/this/path/'
Expand Down
2 changes: 1 addition & 1 deletion docs/source/topics/lists-and-dicts.rst
Original file line number Diff line number Diff line change
Expand Up @@ -96,5 +96,5 @@ as the are required to be strings on MongoDB.) ::
{u'bob' : 3, u'alice' : 42}

DictFields are useful mainly for storing objects of varying shape, i.e. objects
whose structure is unknow at coding time. If all your objects have the same
whose structure is unknown at coding time. If all your objects have the same
structure, you should consider using :doc:`embedded-models`.
4 changes: 2 additions & 2 deletions tests/multiple_database/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ def test_o2o_separation(self):
alice_profile = UserProfile.objects.using('default').get(flavor='chocolate')
bob_profile = UserProfile.objects.using('other').get(flavor='crunchy frog')

# Retrive related object by descriptor. Related objects should be database-baound
# Retrive related object by descriptor. Related objects should be database-bound
self.assertEqual(alice_profile.user.username, 'alice')
self.assertEqual(bob_profile.user.username, 'bob')

Expand Down Expand Up @@ -466,7 +466,7 @@ def test_db_selection(self):
self.assertEqual(Book.objects.db_manager('default').all().db, 'default')

def test_syncdb_selection(self):
"Synchronization behaviour is predicatable"
"Synchronization behaviour is predictable"

self.assertTrue(router.allow_syncdb('default', User))
self.assertTrue(router.allow_syncdb('default', Book))
Expand Down
2 changes: 1 addition & 1 deletion tests/query/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,7 @@ def test_update_with_F(self):
self.assertEqual(Person.objects.get(name='john').age, 39)

def test_update_with_F_and_db_column(self):
# This test is simmilar to test_update_with_F but tests
# This test is similar to test_update_with_F but tests
# the update with a column that has a db_column set.
john = Person.objects.create(name='john', surname='nhoj',
another_age=42)
Expand Down