Skip to content

Commit f76ea0f

Browse files
authored
Auth update
1 parent b46c5e7 commit f76ea0f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Vision/ComputerVision/src/main/java/ComputerVisionQuickstart.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,14 +55,14 @@ public static void main(String[] args) {
5555
* Create a client that authorizes your Computer Vision subscription key and region.
5656
*/
5757
String subscriptionKey = System.getenv("COMPUTER_VISION_SUBSCRIPTION_KEY");
58-
if (subscriptionKey != "COMPUTER_VISION_SUBSCRIPTION_KEY") {
58+
if (subscriptionKey == null) {
5959
System.out.println("\n\nPlease set the COMPUTER_VISION_SUBSCRIPTION_KEY environment variable." +
6060
"\n**You might need to restart your shell or IDE after setting it.**\n");
6161
System.exit(0);
6262
}
6363

6464
String endpoint = System.getenv("COMPUTER_VISION_ENDPOINT");
65-
if (endpoint != "COMPUTER_VISION_ENDPOINT") {
65+
if (endpoint == null) {
6666
System.out.println("\n\nPlease set the COMPUTER_VISION_ENDPOINT environment variable." +
6767
"\n**You might need to restart your shell or IDE after setting it.**\n");
6868
System.exit(0);

0 commit comments

Comments
 (0)