Skip to content

Commit

Permalink
Merge branch 'swiftyos/open-2276-add-ability-to-execute-store-agents-…
Browse files Browse the repository at this point in the history
…without-agent-ownership' of github.com:Significant-Gravitas/AutoGPT into swiftyos/open-2276-add-ability-to-execute-store-agents-without-agent-ownership
  • Loading branch information
Swiftyos committed Jan 10, 2025
2 parents 8adf7bf + 714913a commit 9e008ad
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions autogpt_platform/backend/backend/data/graph.py
Original file line number Diff line number Diff line change
Expand Up @@ -562,8 +562,8 @@ async def get_graph(

# The Graph has to be owned by the user or a store listing.
if (
graph
and graph.userId != user_id
graph is None
or graph.userId != user_id
and not (
await StoreListingVersion.prisma().find_first(
where=prisma.types.StoreListingVersionWhereInput(
Expand All @@ -577,8 +577,7 @@ async def get_graph(
):
return None

# If it is a store listing, return the graph model
return GraphModel.from_db(graph, for_export) if graph else None
return GraphModel.from_db(graph, for_export)


async def set_graph_active_version(graph_id: str, version: int, user_id: str) -> None:
Expand Down

0 comments on commit 9e008ad

Please sign in to comment.