"Wrap chained method calls" settings affects members after indexer
Hello. I have setting "Wrap chained method calls" is set by "Chop always" value. Link to .DotSettngs file
Options -> Code Editing -> C# -> Formatting style -> Line Beaks and Wrapping -> Arrangement of Member Access Expressions -> Wrap chained method calls = Chop always
It works good for methods:
//Before cleanup
var isFoo = scriptsFolder.ToLower().Trim().StartsWith("foo");
//After cleanup
var isFoo = scriptsFolder.ToLower()
.Trim()
.StartsWith("foo");
But I have indexers in code. And this setting effects them:
//Before cleanup
var conString = ConfigurationManager.ConnectionStrings["Db"].ConnectionString
//After cleanup
var conString = ConfigurationManager.ConnectionStrings["Db"]
.ConnectionString
I don't want the member ConnectionString to be relocated to new line. Say me, please, what should I do to achieve it?
Thank you.
Please sign in to leave a comment.
Hello Egor!
Thank you for contacting us.
It seems to be a bug, here's correspondent issue report - https://youtrack.jetbrains.com/issue/RSRP-464682.
You are welcome to comment or vote for it.
Thank you.
Thank you, Angelina.