Skip to content

Commit

Permalink
chore: reduce account code width
Browse files Browse the repository at this point in the history
  • Loading branch information
vindard committed Jan 16, 2025
1 parent ef4c9a8 commit d3a2ffd
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions core/chart-of-accounts/src/path/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ use serde::{Deserialize, Serialize};
use super::primitives::{ChartId, DebitOrCredit};
use error::*;

const ENCODED_PATH_WIDTH: usize = 8;
const ENCODED_PATH_WIDTH: usize = 5;

#[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Serialize, Hash, Deserialize)]
pub struct AccountIdx(u64);
Expand All @@ -25,7 +25,6 @@ impl From<u32> for AccountIdx {
impl AccountIdx {
pub const FIRST: Self = Self(1);
pub const MAX_TWO_DIGIT: Self = Self(99);
pub const MAX_THREE_DIGIT: Self = Self(999);

pub const fn next(&self) -> Self {
Self(self.0 + 1)
Expand Down

0 comments on commit d3a2ffd

Please sign in to comment.