Skip to content
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

fix: .Site.IsServer -> hugo.IsServer #217

Closed
wants to merge 1 commit into from
Closed

fix: .Site.IsServer -> hugo.IsServer #217

wants to merge 1 commit into from

Conversation

ggrs
Copy link

@ggrs ggrs commented Oct 10, 2024

.Site.IsServer is deprecated

.Site.IsServer is deprecated
@ggrs ggrs closed this by deleting the head repository Oct 11, 2024
@StefMa
Copy link
Owner

StefMa commented Oct 11, 2024

@ggrs why did you closed this?
I guess we can go with that 🙃

@dominiklanger
Copy link

@StefMa : Just run into the same problem... Results in an error with hugo v0.134. Could you implement the change suggested by ggrs's pull request (since he closed it) or shall I create a new pull request?

@StefMa
Copy link
Owner

StefMa commented Oct 12, 2024

@dominiklanger i just created #218. But it seems that is a breaking change...
Do you know with which version Hugo introduced hugo.IsServer?

@StefMa
Copy link
Owner

StefMa commented Oct 12, 2024

Or another question..
Is .Site.IsServer removed now? Or still just an deprecation?

@dominiklanger
Copy link

@StefMa

@StefMa
Copy link
Owner

StefMa commented Oct 13, 2024

Here it says it is still available, no? 🤔

https://gohugo.io/methods/site/isserver/

@dominiklanger
Copy link

dominiklanger commented Oct 13, 2024

With Hugo v.0.134, I got the following ERROR message for the hugo server command:

ERROR deprecated: .Site.IsServer was deprecated in Hugo v0.120.0 and will be removed in Hugo 0.135.0. Use hugo.IsServer instead.

I now upgraded to Hugo v.0.135, still get an error message, though slightly different:

ERROR deprecated: .Site.IsServer was deprecated in Hugo v0.120.0 and will be removed in Hugo 0.136.0. Use hugo.IsServer instead.

An error is the third stage in their escalation of deprecation level: https://gohugo.io/troubleshooting/deprecation/

Would be great if the newest version in the MASTER branch runs without problems with the newest Hugo version.

@StefMa
Copy link
Owner

StefMa commented Oct 14, 2024

Thanks @dominiklanger !

I fixed it here #218 and a release is out with that.
See https://github.com/StefMa/hugo-fresh/releases/tag/v1.2.0

Thanks for the follow-up help 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants