Skip to content

Commit

Permalink
fix path validation in graphql (#1802)
Browse files Browse the repository at this point in the history
  • Loading branch information
ricopinazo authored Oct 2, 2024
1 parent 81fb3a9 commit bafc7fb
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions raphtory-graphql/src/paths.rs
Original file line number Diff line number Diff line change
Expand Up @@ -106,14 +106,9 @@ impl ValidGraphFolder {
Component::ParentDir => return Err(ParentDirNotAllowed(user_facing_path)),
Component::Normal(component) => {
// check if some intermediate path is already a graph
let result = ExistingGraphFolder::try_from(
base_path.clone(),
full_path.to_str().unwrap(),
);
if result.is_ok() {
if full_path.join(".raph").exists() {
return Err(ParentIsGraph(user_facing_path));
}

//check for symlinks
full_path.push(component);
if full_path.is_symlink() {
Expand Down

0 comments on commit bafc7fb

Please sign in to comment.