Fix indentation in multiline strings
This commit is contained in:
@@ -88,13 +88,13 @@ pub mod station {
|
|||||||
|
|
||||||
fn init_crypto(&mut self, response: &str) -> Result<(), StationError> {
|
fn init_crypto(&mut self, response: &str) -> Result<(), StationError> {
|
||||||
let re = Regex::new(
|
let re = Regex::new(
|
||||||
r"(?x) # Ignore whitespace; allow line comments
|
r"(?x) # Ignore whitespace; allow line comments
|
||||||
(\W|^) [[:space:]]* # Start of Javascript statement
|
(\W|^) [[:space:]]* # Start of Javascript statement
|
||||||
var [[:space:]]+ (?P<varName>[[:word:]]+) # variable declaration
|
var [[:space:]]+ (?P<varName>[[:word:]]+) # variable declaration
|
||||||
[[:space:]]* = [[:space:]]* # Equals sign
|
[[:space:]]* = [[:space:]]* # Equals sign
|
||||||
'(?P<strval>[^']*)' # String value
|
'(?P<strval>[^']*)' # String value
|
||||||
[[:space:]]*; # End of statement
|
[[:space:]]*; # End of statement
|
||||||
",
|
",
|
||||||
)
|
)
|
||||||
.unwrap();
|
.unwrap();
|
||||||
|
|
||||||
@@ -137,9 +137,9 @@ pub mod station {
|
|||||||
.init_crypto(
|
.init_crypto(
|
||||||
format!(
|
format!(
|
||||||
r"var currentSessionId = '{}';
|
r"var currentSessionId = '{}';
|
||||||
var myIv = '{}';
|
var myIv = '{}';
|
||||||
var mySalt = '{}';
|
var mySalt = '{}';
|
||||||
",
|
",
|
||||||
&session_id, &iv, &salt
|
&session_id, &iv, &salt
|
||||||
)
|
)
|
||||||
.as_str(),
|
.as_str(),
|
||||||
|
|||||||
Reference in New Issue
Block a user