-
-
Notifications
You must be signed in to change notification settings - Fork 5.4k
Desktop: Allow changing user agent when syncing #2050
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Desktop: Allow changing user agent when syncing #2050
Conversation
Thanks for the pull request. There's no need to manually change the user agent so let's hard code it to "Joplin/1.0" for now. Also please check that the header is not already set before setting it (it makes the code a bit more durable, in case the caller changes it to something else). |
Regarding my initial request on #2042 , a hardcoded a user-agent would suffice nicely for my use case. |
Yes I don't see a requirement for spoofing the user agent at this point. It could be needed later on, but for now just a hard-coded string would work. |
So the best way to handle this would be to just change the value to |
Yes hard coded directly in WebDavApi, with no setting. So i guess the pull request would really just be one line of code. |
@AlexPaphitis are you planning to do the requested changes or is this another one-fire-Hacktoberfest-PR which is now abandoned? (Sorry, this sounded harsher than it was meant.) |
Closing due to no answer. |
If required, I can create a separate PR with a hard-coded user-agent string change, like given in this PR. |
@Ardakilic, yes definitely, the PR would be accepted as this hard-coded string is all we need. |
Awesome! I'm currently at work, so I'll see what I can do in the evening. |
If not, no worries. I have it already in a local branch. I am not gonna push it, in case you want to create the PR yourself.
Please don't forget to also test if the header has already been set.
Or, if you are ok with it, I can create the PR. Your choice.
|
@Ardakilic since you haven't replied, here's the new PR: #2064 |
Timezones man, they suck on global projects for cases like these. I was working on this now, and yes it took longer than I've anticipated, because I also have to build the development environment of Joplin to test the headers as you've mentioned. I could just add the line and have sent a PR, which was my initial thought. Anyways, thank you @tessus for not keeping this issue orphan. |
Hi hope you're all well :)
This is a pull request to allow changing the user agent used when syncing in both the CLI and Desktop versions of Joplin. The user agent default value is set to Joplin.
I wanted to add this because of the raised issue #2042
Thank you,
Alex