Commit a3325ac9 by Oleg Marshev

Remove ignore codes.

parent 47e469dd
...@@ -16,13 +16,15 @@ class Command(BaseCommand): ...@@ -16,13 +16,15 @@ class Command(BaseCommand):
action='store_true', action='store_true',
dest='drop', dest='drop',
default=False, default=False,
help='Recreate index'), help='Recreate index'
),
) )
def handle(self, *args, **options): def handle(self, *args, **options):
if options['drop']: if options['drop']:
# drop existing # drop existing
get_es().indices.delete(index=settings.ES_INDEXES['default'], ignore=404) get_es().indices.delete(index=settings.ES_INDEXES['default'])
get_es().indices.create( get_es().indices.create(
index=settings.ES_INDEXES['default'], index=settings.ES_INDEXES['default'],
body={ body={
...@@ -30,5 +32,4 @@ class Command(BaseCommand): ...@@ -30,5 +32,4 @@ class Command(BaseCommand):
NoteMappingType.get_mapping_type_name(): NoteMappingType.get_mapping() NoteMappingType.get_mapping_type_name(): NoteMappingType.get_mapping()
} }
}, },
ignore=400 # ignore when present
) )
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment