Skip to content

Commit 9b9ad42

Browse files
danielhoherdSteadBytes
authored andcommitted
Fix some typos (#714)
* Fix some typos * s/modal/model/
1 parent a7e363a commit 9b9ad42

File tree

8 files changed

+14
-14
lines changed

8 files changed

+14
-14
lines changed

doc/marshalling.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ You can use fields to multiplex a single attribute to multiple output values.
120120
This example assumes that bit 1 in the ``flags`` attribute signifies a
121121
"Normal" or "Urgent" item, and bit 2 signifies "Read" or "Unread".
122122
These items might be easy to store in a bitfield,
123-
but for a human readable output it's nice to convert them to seperate string fields.
123+
but for a human readable output it's nice to convert them to separate string fields.
124124

125125
.. code-block:: python
126126

doc/parsing.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ The :mod:`~flask_restplus.inputs` module provides some common type handling like
173173

174174
- :func:`~inputs.boolean` for wider boolean handling
175175
- :func:`~inputs.ipv4` and :func:`~inputs.ipv6` for IP adresses
176-
- :func:`~inputs.date_from_iso8601` and :func:`~inputs.datetime_from_iso8601` for ISO8601 date and dateime handling
176+
- :func:`~inputs.date_from_iso8601` and :func:`~inputs.datetime_from_iso8601` for ISO8601 date and datetime handling
177177

178178
You just have to use them as `type` argument:
179179

@@ -193,7 +193,7 @@ You can also write your own:
193193
raise ValueError('This is not my type')
194194
return parse(value)
195195
196-
# Swagger documntation
196+
# Swagger documentation
197197
my_type.__schema__ = {'type': 'string', 'format': 'my-custom-format'}
198198
199199

doc/swagger.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -590,7 +590,7 @@ Models can also be specified with a :class:`~flask_restplus.reqparse.RequestPars
590590
591591
.. note::
592592

593-
Using :class:`~flask_restplus.reqparse.RequestParser` is prefered over the ``api.param()`` decorator
593+
Using :class:`~flask_restplus.reqparse.RequestParser` is preferred over the ``api.param()`` decorator
594594
to document form fields as it also perform validation.
595595

596596
Headers
@@ -862,7 +862,7 @@ It supports both extensions as `dict` or `kwargs` and perform automatique `x-` p
862862
class Vendor(Resource):
863863
@api.vendor({
864864
'extension-1': {'works': 'with complex values'},
865-
'x-extension-3': 'x- prefix is optionnal',
865+
'x-extension-3': 'x- prefix is optional',
866866
})
867867
def get(self):
868868
return {}

flask_restplus/api.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -358,7 +358,7 @@ def make_response(self, data, *args, **kwargs):
358358
raise InternalServerError()
359359

360360
def documentation(self, func):
361-
'''A decorator to specify a view funtion for the documentation'''
361+
'''A decorator to specify a view function for the documentation'''
362362
self._doc_view = func
363363
return func
364364

@@ -379,7 +379,7 @@ def default_endpoint(self, resource, namespace):
379379
380380
Endpoints are ensured not to collide.
381381
382-
Override this method specify a custom algoryhtm for default endpoint.
382+
Override this method specify a custom algorithm for default endpoint.
383383
384384
:param Resource resource: the resource for which we want an endpoint
385385
:param Namespace namespace: the namespace holding the resource
@@ -565,7 +565,7 @@ def _has_fr_route(self):
565565

566566
def error_router(self, original_handler, e):
567567
'''
568-
This function decides whether the error occured in a flask-restplus
568+
This function decides whether the error occurred in a flask-restplus
569569
endpoint or not. If it happened in a flask-restplus endpoint, our
570570
handler will be dispatched. If it happened in an unrelated view, the
571571
app's original error handler will be dispatched.

flask_restplus/errors.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,10 @@ def __str__(self):
4747

4848

4949
class ValidationError(RestError):
50-
'''An helper class for validation errors.'''
50+
'''A helper class for validation errors.'''
5151
pass
5252

5353

5454
class SpecsError(RestError):
55-
'''An helper class for incoherent specifications.'''
55+
'''A helper class for incoherent specifications.'''
5656
pass

flask_restplus/mask.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ def parse(self, mask):
9191
raise ParseError('Missing closing bracket')
9292

9393
def clean(self, mask):
94-
'''Remove unecessary characters'''
94+
'''Remove unnecessary characters'''
9595
mask = mask.replace('\n', '').strip()
9696
# External brackets are optional
9797
if mask[0] == '{':
@@ -132,7 +132,7 @@ def filter_data(self, data):
132132
Handle the data filtering given a parsed mask
133133
134134
:param dict data: the raw data to filter
135-
:param list mask: a parsed mask tofilter against
135+
:param list mask: a parsed mask to filter against
136136
:param bool skip: whether or not to skip missing fields
137137
138138
'''

flask_restplus/model.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ def extend(self, name, fields):
188188
:param str name: The new model name
189189
:param dict fields: The new model extra fields
190190
191-
:depreated: since 0.9. Use :meth:`clone` instead.
191+
:deprecated: since 0.9. Use :meth:`clone` instead.
192192
'''
193193
warnings.warn('extend is is deprecated, use clone instead', DeprecationWarning, stacklevel=2)
194194
if isinstance(fields, (list, tuple)):

flask_restplus/namespace.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ def clone(self, name, *specs):
194194

195195
def inherit(self, name, *specs):
196196
'''
197-
Inherit a modal (use the Swagger composition pattern aka. allOf)
197+
Inherit a model (use the Swagger composition pattern aka. allOf)
198198
199199
.. seealso:: :meth:`Model.inherit`
200200
'''

0 commit comments

Comments
 (0)