payprop / html-googlemaps-v3

Fork of HTML::GoogleMaps to fix issues
2 stars 1 forks source link

API key Is put in code #7

Closed nigelhorne closed 7 years ago

nigelhorne commented 7 years ago

According to Google

"Do not embed API keys directly in code: API keys that are embedded in code can be accidentally exposed to the public—for example, if you forget to remove the keys from code that you share. Instead of embedding your API keys in your applications, store them in environment variables or in files outside of your application's source tree."

I tend to agree. I think if the api_key option is given to new() that should be used for the data lookup, but not get embedded in the result from onload_render().

leejo commented 7 years ago

I'm going to say "patches welcome" on this one.

nigelhorne commented 7 years ago

Before I write the patch, please take a look at the patch I've just submitted to new() - I believe that needs to be added first.

leejo commented 7 years ago

9 has been merged.