Skip to content

Commit c5f1606

Browse files
authored
Merge pull request #341 from p1c2u/rafactor/parse-path-parameter-refactor
parse path parameter refactor
2 parents 0e9850e + 5bb9ea8 commit c5f1606

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

openapi_core/templating/util.py

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,16 @@ def _handle_field(self, field):
1010
path_parameter_field)
1111

1212

13-
def parse_path_parameter(text):
14-
return text
13+
class PathParameter(object):
1514

15+
name = "PathParameter"
16+
pattern = r"[^\/]+"
1617

17-
parse_path_parameter.pattern = r"[^\/]+"
18-
parse_path_parameter.name = "PathParameter"
18+
def __call__(self, text):
19+
return text
20+
21+
22+
parse_path_parameter = PathParameter()
1923

2024

2125
def search(path_pattern, full_url_pattern):

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy