Skip to content
This repository has been archived by the owner on Feb 28, 2022. It is now read-only.

First Pass At StyleCop Integration #23

Merged
merged 18 commits into from
Mar 10, 2020

Conversation

mark-monteiro
Copy link
Contributor

@mark-monteiro mark-monteiro commented Dec 22, 2019

This includes a first pass at integrating StyleCop, addressing many of the outstanding issues.

I am splitting this into multiple PRs to make code review more manageable. For example, in the next PR I will probably tackle all the instances of multiple classes per file, which would produce a fairly unreadable diff if it was combined with this PR. For now, the unaddressed StyleCop issues have been disabled in the .ruleset file.

[SuppressMessage("Usage", "CA2227:Collection properties should be read only", Justification = "This property needs to support serialization by both ServiceStack and XmlSerializer")]
public List<SmartMatchInfo> SmartMatchInfos { get; set; }
public List<SmartMatchInfo> SmartMatchInfos { get; set; } = new List<SmartMatchInfo>();
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Property is initialized here to avoid using the obsolete SmartMatchInfo class in the constructor, which raises an additional warning.

<Rule Id="SA1611" Action="Info" />
<!-- disable Warning SA1649: File name should match first type -->
<Rule Id="SA1649" Action="Info" />
</Rules>
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Disabling these rules for now, I will remove these ruleset entries one-by one in future PRs.

@mark-monteiro mark-monteiro marked this pull request as ready for review January 6, 2020 15:06
Copy link
Member

@Bond-009 Bond-009 left a comment

Choose a reason for hiding this comment

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

Sorry this took so long, I wasn't watching this repo

Emby.AutoOrganize/Model/FileOrganizationResult.cs Outdated Show resolved Hide resolved
Emby.AutoOrganize/PluginEntryPoint.cs Outdated Show resolved Hide resolved
@mark-monteiro
Copy link
Contributor Author

Sorry this took so long, I wasn't watching this repo

No problem, this isn't something I care about merging quickly ;)

All done with the first few changes you suggested.

@mark-monteiro mark-monteiro requested a review from Bond-009 March 4, 2020 19:47
@Bond-009 Bond-009 merged commit 116d2ee into jellyfin-archive:master Mar 10, 2020
@mark-monteiro mark-monteiro deleted the integrate-stylecop branch March 14, 2020 15:28
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants