Skip to content
This repository has been archived by the owner on Jun 13, 2023. It is now read-only.

Commit

Permalink
fix(wrapper): fixing python handling of pathes with /
Browse files Browse the repository at this point in the history
  • Loading branch information
galbash authored and Ron Yishai committed Dec 25, 2018
1 parent 454e3f4 commit b75e7b3
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/handlers.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,13 @@ export function generateWrapperCode(
wrapper = DEFAULT_WRAPPERS[func.language];
}

const relativePath = (
func.language === 'python' ?
func.relativePath.replace('/', '.').replace('\\', '.') :
func.relativePath
);
return WRAPPER_CODE[func.language]
.replace(/RELATIVE_PATH/g, func.relativePath)
.replace(/RELATIVE_PATH/g, relativePath)
.replace(/METHOD/g, func.method)
.replace(/WRAPPER_TYPE/g, wrapper)
.replace(/TOKEN/g, epsagonConf.token)
Expand Down

0 comments on commit b75e7b3

Please sign in to comment.