Add MicrososftTranslateClient to new namespace

- Rename to Client
- Add to new namespace RemoteTranslations::Microsoft
- Update references to new namespace
This commit is contained in:
taitus
2019-05-24 15:13:15 +02:00
committed by voodoorai2000
parent 91ba5ff879
commit d29656d78f
5 changed files with 35 additions and 35 deletions

View File

@@ -1,7 +1,7 @@
module SentencesParser
def detect_split_position(text)
minimum_valid_index = text.size - MicrosoftTranslateClient::CHARACTERS_LIMIT_PER_REQUEST
minimum_valid_index = text.size - RemoteTranslations::Microsoft::Client::CHARACTERS_LIMIT_PER_REQUEST
valid_point = text[minimum_valid_index..text.size].index(".")
valid_whitespace = text[minimum_valid_index..text.size].index(" ")