修复寻找依赖接口,只能找yaml结尾文件,不能找yml结尾文件的问题
This commit is contained in:
@@ -28,7 +28,7 @@ def get_api_data(api_file_path: str, key: str = None):
|
||||
api_data = []
|
||||
if os.path.isdir(api_file_path):
|
||||
logger.debug(f"目标路径是一个目录:{api_file_path}")
|
||||
api_files = get_files(target=api_file_path, end=".yaml")
|
||||
api_files = get_files(target=api_file_path, end=".yaml") + get_files(target=api_file_path, end=".yml")
|
||||
for api_file in api_files:
|
||||
api_data.append(YamlHandle(filename=api_file).read_yaml)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user