Skip to content

Commit

Permalink
Merge branch 'main' into 2175-wait-for-model-in-inference-client
Browse files Browse the repository at this point in the history
  • Loading branch information
Wauplin authored Jun 10, 2024
2 parents 86ce530 + 6e15d6b commit 772851f
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 2 deletions.
15 changes: 15 additions & 0 deletions .github/workflows/trufflehog.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
on:
push:

name: Secret Leaks

jobs:
trufflehog:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Secret Scanning
uses: trufflesecurity/trufflehog@main
4 changes: 2 additions & 2 deletions src/huggingface_hub/repository.py
Original file line number Diff line number Diff line change
Expand Up @@ -542,10 +542,10 @@ def __init__(
user = self.client.whoami(self.huggingface_token)

if git_email is None:
git_email = user["email"]
git_email = user.get("email")

if git_user is None:
git_user = user["fullname"]
git_user = user.get("fullname")

if git_user is not None or git_email is not None:
self.git_config_username_and_email(git_user, git_email)
Expand Down

0 comments on commit 772851f

Please sign in to comment.