fix(rustup): Remove uses of the obsolete &a[] syntax
This commit is contained in:
committed by
Sean McArthur
parent
234fcdc3a2
commit
039e984f68
@@ -29,7 +29,7 @@ impl header::Header for AccessControlAllowOrigin {
|
||||
|
||||
fn parse_header(raw: &[Vec<u8>]) -> Option<AccessControlAllowOrigin> {
|
||||
if raw.len() == 1 {
|
||||
match str::from_utf8(unsafe { &raw[].get_unchecked(0)[] }) {
|
||||
match str::from_utf8(unsafe { &raw.get_unchecked(0)[..] }) {
|
||||
Ok(s) => {
|
||||
if s == "*" {
|
||||
Some(AccessControlAllowOrigin::AllowStar)
|
||||
|
||||
Reference in New Issue
Block a user