]> git.vanrenterghem.biz Git - R/project-wa-schools.git/commitdiff
Remove redundant list().
authorFrederik Vanrenterghem <frederik@vanrenterghem.biz>
Mon, 2 Oct 2023 14:40:12 +0000 (22:40 +0800)
committerFrederik Vanrenterghem <frederik@vanrenterghem.biz>
Mon, 2 Oct 2023 14:40:12 +0000 (22:40 +0800)
WA_active_schools.R

index 0811702e1d00d2da6f87af44d384f7f53ec01636..ae59595e3d2532f327215e2a91cdc24f0cfc0984 100644 (file)
@@ -11,11 +11,11 @@ tempdirSHP <- tempdir()
 tempfileSHP <- tempfile()
 req <- request("https://sso.slip.wa.gov.au/as/token.oauth2") |>
     req_headers("Authorization" = "Basic ZGlyZWN0LWRvd25sb2Fk") |>
-    req_body_form(list("grant_type" = "password",
-                       # SLIP username and password stored in
-                       #pass - the standard unix password manager
-                       "username" = system2("pass", args = "slip.wa.gov.au | grep Username | sed -e 's/Username: //'", stdout = TRUE),
-                       "password" = system2("pass", args = "slip.wa.gov.au | head -1", stdout = TRUE)))
+    req_body_form(grant_type = "password",
+                  # SLIP username and password stored in
+                  pass - the standard unix password manager
+                  username = system2("pass", args = "slip.wa.gov.au | grep Username | sed -e 's/Username: //'", stdout = TRUE),
+                  password = system2("pass", args = "slip.wa.gov.au | head -1", stdout = TRUE))
 
 tokenResponse <- req_perform(req)