r0gue-io / pop-cli

An all-in-one tool for Polkadot development.
GNU General Public License v3.0
57 stars 17 forks source link

fix: invalid .expect when parsing args with intro of pop install command #187

Closed peterwht closed 1 month ago

peterwht commented 1 month ago

Telemetry would parse and use two args: command and subcommand. Before pop install all commands were guaranteed to have at least 3 arguments. However, pop install does not have a subcommand, and hence additional checks were needed to handle only 2 arguments.

codecov[bot] commented 1 month ago

Codecov Report

Attention: Patch coverage is 70.37037% with 8 lines in your changes are missing coverage. Please review.

Project coverage is 50.59%. Comparing base (047bee3) to head (230847b).

@@            Coverage Diff             @@
##             main     #187      +/-   ##
==========================================
+ Coverage   50.28%   50.59%   +0.31%     
==========================================
  Files          32       32              
  Lines        2828     2848      +20     
  Branches     2828     2848      +20     
==========================================
+ Hits         1422     1441      +19     
- Misses       1183     1184       +1     
  Partials      223      223              
Files Coverage Δ
crates/pop-cli/src/main.rs 27.41% <70.37%> (+12.99%) :arrow_up: