Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: 2.6.2 to 3.0.0 sf::Http::Request  (Read 416 times)

0 Members and 1 Guest are viewing this topic.

HeinzK

  • Jr. Member
  • **
  • Posts: 57
    • View Profile
    • ZwiAner
    • Email
2.6.2 to 3.0.0 sf::Http::Request
« on: January 23, 2025, 04:47:04 pm »
sf::Http::Request rqst;
V2:
rqst.setMethod(sf::Http::Request::Post);
V3:
rqst.setMethod(sf::Http::Request::Method::Post);
.. is this correct ?

V2:
if
(
  (rsps.getStatus() > 199)
  &&
  (rsps.getStatus() < 300)
)
.. what ist wrong ?.
The trees, that obstruct the view on the forest, can be allowed to fall! (Die Bäume, die die Sicht auf einen Wald versperren, dürfen gefällt werden!)

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11107
    • View Profile
    • development blog
    • Email
Re: 2.6.2 to 3.0.0 sf::Http::Request
« Reply #1 on: January 23, 2025, 08:09:01 pm »
sf::Http::Request rqst;
V2:
rqst.setMethod(sf::Http::Request::Post);
V3:
rqst.setMethod(sf::Http::Request::Method::Post);
.. is this correct ?
Yes

V2:
if
(
  (rsps.getStatus() > 199)
  &&
  (rsps.getStatus() < 300)
)
.. what ist wrong ?.
The status is now a scope enum, which you can't directly compare to an integer.
If you still want to do that, you'll need to cast the status to an integer type.
Official FAQ: https://www.sfml-dev.org/faq/
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

 

anything