Skip to content

Refactor WriteFreelyClient to use RequestTemplates #7

@AngeloStavrow

Description

@AngeloStavrow

Currently, WriteFreelyClient is not especially DRY — because so much of the request code is repeatable, it would make more sense to pull that out into a RequestTemplate of sorts.

This should also help with the type_body_length linting issue for the WriteFreelyClient class being too long:

Type body should span 200 lines or less excluding comments and whitespace: currently spans 519 lines

(This exceeds SwiftLint's warning level, and would instead be a build-blocking error once #6 is implemented, so this should be labeled a bug rather than an enhancement.)

Useful reference: "Keeping Your Network Layer Clean With DRY" by Frank Courville

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions