summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--js/fetch_types.d.ts2
-rw-r--r--js/os.ts2
-rw-r--r--src/handlers.rs14
3 files changed, 9 insertions, 9 deletions
diff --git a/js/fetch_types.d.ts b/js/fetch_types.d.ts
index ebe2c70be..4f77b5bd1 100644
--- a/js/fetch_types.d.ts
+++ b/js/fetch_types.d.ts
@@ -145,7 +145,7 @@ interface File extends Blob {
declare var File: {
prototype: File;
- new(fileBits: BlobPart[], fileName: string, options?: FilePropertyBag): File;
+ new (fileBits: BlobPart[], fileName: string, options?: FilePropertyBag): File;
};
interface FilePropertyBag extends BlobPropertyBag {
diff --git a/js/os.ts b/js/os.ts
index f0f8897cc..46385c493 100644
--- a/js/os.ts
+++ b/js/os.ts
@@ -187,7 +187,7 @@ export class FileInfo {
this.len = this._msg.len().toFloat64();
this.modified = this._msg.modified().toFloat64();
this.accessed = this._msg.accessed().toFloat64();
- this.created = created ? created: null;
+ this.created = created ? created : null;
}
isFile() {
diff --git a/src/handlers.rs b/src/handlers.rs
index 564f5e5be..8d321c46f 100644
--- a/src/handlers.rs
+++ b/src/handlers.rs
@@ -14,8 +14,8 @@ use hyper::Client;
use msg_generated::deno as msg;
use std;
use std::fs;
-use std::time::UNIX_EPOCH;
use std::path::Path;
+use std::time::UNIX_EPOCH;
use std::time::{Duration, Instant};
use tokio::prelude::future;
use tokio::prelude::*;
@@ -479,12 +479,12 @@ macro_rules! to_seconds {
($time:expr) => {{
// Unwrap is safe here as if the file is before the unix epoch
// something is very wrong.
- $time.and_then(|t| Ok(t.duration_since(UNIX_EPOCH).unwrap().as_secs()))
- .unwrap_or(0)
- }}
+ $time
+ .and_then(|t| Ok(t.duration_since(UNIX_EPOCH).unwrap().as_secs()))
+ .unwrap_or(0)
+ }};
}
-
fn handle_stat_sync(
_d: *const DenoC,
builder: &mut FlatBufferBuilder,
@@ -494,9 +494,9 @@ fn handle_stat_sync(
debug!("handle_stat_sync {} {}", filename, lstat);
let path = Path::new(filename);
let metadata = if lstat {
- fs::symlink_metadata(path)?
+ fs::symlink_metadata(path)?
} else {
- fs::metadata(path)?
+ fs::metadata(path)?
};
let msg = msg::StatSyncRes::create(