Skip to content

Conversation

armanbilge
Copy link
Member

Fixes #6363.

@armanbilge armanbilge changed the title Follow links when accessing file attributes in StaticFiles Follow links when accessing file attributes in StaticFile May 6, 2022
@mergify mergify bot added series/0.23 PRs targeting 0.23.x module:core labels May 6, 2022
.fromPath[IO](Path("tests/shared/src/test/resources/lipsum-symlink.txt"))
.semiflatMap(_.body.compile.count)
.getOrElse(0)
.assertEquals(24005)
Copy link
Member

@danicheg danicheg May 7, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the magic number? Could we replace it with some computation?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes we can, we can just directly read the size of the file lorem-ipsum.txt instead of via the symlink.

@armanbilge armanbilge merged commit b13d2c9 into http4s:series/0.23 May 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
module:core series/0.23 PRs targeting 0.23.x
Projects
None yet
Development

Successfully merging this pull request may close these issues.

StaticFile on symbolic link
2 participants