Skip to content

Commit

Permalink
ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
davidzhao committed Oct 1, 2024
1 parent 0bbc49d commit d794195
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions livekit-api/livekit/api/access_token.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,13 +144,11 @@ def with_sha256(self, sha256: str) -> "AccessToken":
def to_jwt(self) -> str:
video = self.claims.video
if video.room_join and (not self.identity or not video.room):
raise ValueError(
"identity and room must be set when joining a room")
raise ValueError("identity and room must be set when joining a room")

claims = dataclasses.asdict(
self.claims,
dict_factory=lambda items: {
snake_to_lower_camel(k): v for k, v in items},
dict_factory=lambda items: {snake_to_lower_camel(k): v for k, v in items},
)
claims.update(
{
Expand Down

0 comments on commit d794195

Please sign in to comment.