Skip to content

Commit

Permalink
remove unnecessary env var from FE
Browse files Browse the repository at this point in the history
  • Loading branch information
nour-bouzid committed Mar 19, 2024
1 parent 3a18f7c commit 19a1249
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 6 deletions.
1 change: 0 additions & 1 deletion .github/workflows/pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ jobs:
VITE_FACE_API_ENDPOINT: ${{secrets.VITE_FACE_API_ENDPOINT}}
VITE_VISION_API_ENDPOINT: ${{secrets.VITE_VISION_API_ENDPOINT}}
VITE_VISION_API_KEY: ${{secrets.VITE_VISION_API_KEY}}
VITE_CHAT_API_KEY: ${{secrets.VITE_CHAT_API_KEY}}
VITE_CHAT_API_ENDPOINT: ${{secrets.VITE_CHAT_API_ENDPOINT}}
working-directory: frontend

Expand Down
4 changes: 2 additions & 2 deletions frontend/src/components/Navbar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ import {
faceApiEndpoint,
speechApiKey,
visionApiKey,
chatApiKey,
chatApiEndpoint,
} from "../settings";
@Component
Expand All @@ -62,7 +62,7 @@ export default class Navbar extends Vue {
return visionApiKey !== "";
}
get showChatButton(): boolean {
return chatApiKey !== "";
return chatApiEndpoint !== "";
}
}
</script>
Expand Down
3 changes: 0 additions & 3 deletions frontend/src/settings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ const faceApiEndpoint = import.meta.env.VITE_FACE_API_ENDPOINT || "";
const visionApiKey = import.meta.env.VITE_VISION_API_KEY || "";
const visionApiEndpoint = import.meta.env.VITE_VISION_API_ENDPOINT || "";
const chatApiEndpoint = import.meta.env.VITE_CHAT_API_ENDPOINT || "";
const chatApiKey = import.meta.env.VITE_CHAT_API_KEY || "";


export {
imageApiUrl,
Expand All @@ -16,5 +14,4 @@ export {
visionApiKey,
visionApiEndpoint,
chatApiEndpoint,
chatApiKey
};

0 comments on commit 19a1249

Please sign in to comment.