mirror of
https://github.com/ankitects/anki.git
synced 2025-09-25 01:06:35 -04:00
Remove superfluous muts
This commit is contained in:
parent
f04ea5a2c7
commit
769b5ac833
1 changed files with 6 additions and 6 deletions
|
@ -350,7 +350,7 @@ impl RowContext {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fn browser_row(&mut self, columns: &[Column]) -> Result<Row> {
|
fn browser_row(&self, columns: &[Column]) -> Result<Row> {
|
||||||
Ok(Row {
|
Ok(Row {
|
||||||
cells: columns
|
cells: columns
|
||||||
.iter()
|
.iter()
|
||||||
|
@ -361,14 +361,14 @@ impl RowContext {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fn get_cell(&mut self, column: Column) -> Result<Cell> {
|
fn get_cell(&self, column: Column) -> Result<Cell> {
|
||||||
Ok(Cell {
|
Ok(Cell {
|
||||||
text: self.get_cell_text(column)?,
|
text: self.get_cell_text(column)?,
|
||||||
is_rtl: self.get_is_rtl(column),
|
is_rtl: self.get_is_rtl(column),
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fn get_cell_text(&mut self, column: Column) -> Result<String> {
|
fn get_cell_text(&self, column: Column) -> Result<String> {
|
||||||
Ok(match column {
|
Ok(match column {
|
||||||
Column::Question => self.question_str(),
|
Column::Question => self.question_str(),
|
||||||
Column::Answer => self.answer_str(),
|
Column::Answer => self.answer_str(),
|
||||||
|
@ -437,7 +437,7 @@ impl RowContext {
|
||||||
.to_string()
|
.to_string()
|
||||||
}
|
}
|
||||||
|
|
||||||
fn due_str(&mut self) -> String {
|
fn due_str(&self) -> String {
|
||||||
if self.notes_mode {
|
if self.notes_mode {
|
||||||
self.note_due_str()
|
self.note_due_str()
|
||||||
} else {
|
} else {
|
||||||
|
@ -445,7 +445,7 @@ impl RowContext {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fn card_due_str(&mut self) -> String {
|
fn card_due_str(&self) -> String {
|
||||||
let due = if self.cards[0].is_filtered_deck() {
|
let due = if self.cards[0].is_filtered_deck() {
|
||||||
self.tr.browsing_filtered()
|
self.tr.browsing_filtered()
|
||||||
} else if self.cards[0].is_new_type_or_queue() {
|
} else if self.cards[0].is_new_type_or_queue() {
|
||||||
|
@ -524,7 +524,7 @@ impl RowContext {
|
||||||
.date_string()
|
.date_string()
|
||||||
}
|
}
|
||||||
|
|
||||||
fn deck_str(&mut self) -> String {
|
fn deck_str(&self) -> String {
|
||||||
if self.notes_mode {
|
if self.notes_mode {
|
||||||
let decks = self.cards.iter().map(|c| c.deck_id).unique().count();
|
let decks = self.cards.iter().map(|c| c.deck_id).unique().count();
|
||||||
if decks > 1 {
|
if decks > 1 {
|
||||||
|
|
Loading…
Reference in a new issue