added regex-replacealldotsbeforethelast