streamaserver / streama

Self hosted streaming media server. https://docs.streama-project.com/
MIT License
9.61k stars 983 forks source link

Add Language in the API themoviedb #336

Open weslleycsil opened 7 years ago

weslleycsil commented 7 years ago

I think it's a good idea, the content manager chooses the language of the API when adding the data related to the movie / series

In quick research, I believe that just by adding "&language=pt-BR" at the end of the function in file grails-app/services/streama/TheMovieDbService.groovy

def validateApiKey(apiKey){
 +    def JsonContent = new URL(BASE_URL + '/configuration?api_key=' + apiKey+ '&language=pt-BR').text
 +    return new JsonSlurper().parseText(JsonContent)
    }

However dynamically, json is already returned translated.

I'm Brazilian, and I loved your project. I believe that this modification would be of great importance in the future, I know that you also have to have the implementation in the view.

Keep up the good work, I'll be sending you a 'liking' on paypal.

dularion commented 7 years ago

Oh thats very cool idea. Is it something you wish to set per movie/show or for the entire system? How does theMovieDb behave when the language is not available, do you know? does it default to english?