Skip to content

Commit

Permalink
Always open files for sigils if any input files are passed in (#222)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexevanczuk authored Dec 20, 2024
1 parent 44a1770 commit 308909d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

[package]
name = "pks"
version = "0.2.18"
version = "0.2.19"
edition = "2021"
description = "Welcome! Please see https://github.com/alexevanczuk/packs for more information!"
license = "MIT"
Expand Down
6 changes: 4 additions & 2 deletions src/packs/checker/privacy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,13 @@ impl CheckerInterface for Checker {
let absolute_file =
configuration.absolute_root.join(relative_file);

// if configuration.input_files_count is less than 100, we're just going to individually
// if configuration.input_files_count is greater than zero, we're just going to individually
// take the contents of the absolute file and call extract_sigils_from_contents on it to get the sigils
// and then check if a "public" sigil is contained. manual_read_of_defining_file_contains_sigil
// That's because we need to process a file to get the sigils, and if files are inputted, we likely didn't also input
// the file that defines the constant and has the sigil.
let manual_read_of_defining_file_contains_sigil =
if configuration.input_files_count < 100 {
if configuration.input_files_count > 0 {
if let Ok(contents) =
std::fs::read_to_string(&absolute_file)
{
Expand Down

0 comments on commit 308909d

Please sign in to comment.