Skip to content

Commit 51316b5

Browse files
committed
fix tests
1 parent cb9be76 commit 51316b5

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/mcp/actors.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@ export async function getActorDefinition(actorID: string, apifyToken: string): P
6161
const actorObjID = info.id;
6262
const res = await fetch(`${getApifyAPIBaseUrl()}/v2/acts/${actorObjID}/builds/default`, {
6363
headers: {
64-
'Authorization': `Bearer ${apifyToken}`
64+
// This is done so tests can pass with public Actors without token
65+
...(apifyToken ? { 'Authorization': `Bearer ${apifyToken}` } : {})
6566
}
6667
});
6768
if (!res.ok) {

0 commit comments

Comments
 (0)