Skip to content

Commit

Permalink
Fix a bug in an error message
Browse files Browse the repository at this point in the history
The parser ensures that limt != "current", it's always either a Range or
None. Instead, check user_input's value, which might be "current", and
report the current size of the filesystem in that case.

Signed-off-by: mulhern <[email protected]>
  • Loading branch information
mulkieran committed Nov 4, 2024
1 parent 10afe87 commit 79f85dd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/stratis_cli/_actions/_logical.py
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ def set_size_limit(namespace): # pylint: disable=too-many-locals
if valid and new_limit.magnitude == int(str(maybe_size_limit)):
raise StratisCliNoPropertyChangeError(
"Filesystem size limit is exactly "
f'{new_limit if limit == "current" else user_input}'
f'{new_limit if user_input == "current" else user_input}'
)

Filesystem.Properties.SizeLimit.Set(
Expand Down

0 comments on commit 79f85dd

Please sign in to comment.