mirror of
https://github.com/Kong/insomnia.git
synced 2026-10-25 16:19:20 -04:00
Refactor setter method
This commit is contained in:
1 parent
2dd8bd93cd
commit
77321f5fa2
1 file changed
+6
-5
@@ -131,14 +131,15 @@ export function init(
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
setAuthentication(name : string, value: string) : void {
|
||||
renderedRequest.authentication[name] = value;
|
||||
setAuthentication(name: string, value: string): void {
|
||||
Object.assign(renderedRequest.authentication, {
|
||||
[name]: value,
|
||||
});
|
||||
},
|
||||
|
||||
getAuthentication() : Object {
|
||||
getAuthentication(): Object {
|
||||
return renderedRequest.authentication;
|
||||
}
|
||||
},
|
||||
|
||||
// NOTE: For these to make sense, we'd need to account for cookies in the jar as well
|
||||
// addCookie (name: string, value: string): void {}
|
||||
|
||||
Reference in new issue
Block a user