mirror of
https://github.com/Eaglercraft-TeaVM-Fork/eagler-teavm.git
synced 2024-12-22 16:14:10 -08:00
Handle the headers as introduced in HTML/Java version 1.2
This commit is contained in:
parent
d06ca2d2a2
commit
c5452d405c
|
@ -150,6 +150,14 @@ public final class KnockoutFXTest extends KnockoutTCK implements Transfer {
|
|||
break;
|
||||
}
|
||||
String value = data.parameters[i];
|
||||
if (value.startsWith("http.header.")) {
|
||||
String header = value.substring(12);
|
||||
int line = call.getHeaders().indexOf(header);
|
||||
int end = call.getHeaders().indexOf("\n", line);
|
||||
if (line >= 0 && end > line) {
|
||||
value = call.getHeaders().substring(line + header.length() + 1, end).trim();
|
||||
}
|
||||
}
|
||||
if (value.equals("http.method")) {
|
||||
value = call.getMethod();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user