Skip to content

Commit

Permalink
Remove force don't format from non-smart formatters
Browse files Browse the repository at this point in the history
Closes #150
  • Loading branch information
ajayyy committed Dec 6, 2023
1 parent 300b92e commit a516440
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/titles/titleFormatter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ export async function toLowerCaseTitle(str: string): Promise<string> {

let result = "";
for (const word of words) {
if (forceKeepFormatting(word) || (!isGreek && await greekLetterAllowed(word))) {
if (!isGreek && await greekLetterAllowed(word)) {
result += word + " ";
} else {
result += await toLowerCase(word, isTurkiq) + " ";
Expand All @@ -76,7 +76,7 @@ export async function toFirstLetterUppercase(str: string): Promise<string> {
let result = "";
let index = 0;
for (const word of words) {
if (forceKeepFormatting(word) || (!isGreek && await greekLetterAllowed(word))) {
if (!isGreek && await greekLetterAllowed(word)) {
result += word + " ";
} else if (startOfSentence(index, words) && !isNumberThenLetter(word)) {
result += await capitalizeFirstLetter(word, isTurkiq) + " ";
Expand Down

0 comments on commit a516440

Please sign in to comment.