Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to Deno 1.2.0 #47

Merged
merged 6 commits into from
Jul 16, 2020
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
language: python

install:
- curl -fsSL https://deno.land/x/install/install.sh | sh -s v1.1.1
- curl -fsSL https://deno.land/x/install/install.sh | sh -s v1.2.0
- export PATH="$HOME/.deno/bin:$PATH"

script:
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Pogo is an easy-to-use, safe, and expressive framework for writing web servers a

[Documentation](./docs)

*Supports Deno v1.0.0 and higher.*
*Supports Deno v1.2.0 and higher.*

## Contents

Expand Down
8 changes: 4 additions & 4 deletions dependencies.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
import React from 'https://jspm.dev/react@16.13.1';
// @deno-types="https://deno.land/x/types/react-dom/v16.13.1/server.d.ts"
import ReactDOMServer from 'https://jspm.dev/react-dom@16.13.1/server';
import * as cookie from 'https://deno.land/std@v0.56.0/http/cookie.ts';
import * as http from 'https://deno.land/std@v0.56.0/http/server.ts';
import { Status as status, STATUS_TEXT as statusText } from 'https://deno.land/std@v0.56.0/http/http_status.ts';
import * as cookie from 'https://deno.land/std@v0.61.0/http/cookie.ts';
import * as http from 'https://deno.land/std@v0.61.0/http/server.ts';
import { Status as status, STATUS_TEXT as statusText } from 'https://deno.land/std@v0.61.0/http/http_status.ts';
import * as mime from 'https://cdn.pika.dev/mime-types@2.1.27';
import * as path from 'https://deno.land/std@v0.56.0/path/mod.ts';
import * as path from 'https://deno.land/std@v0.61.0/path/mod.ts';

export {
React,
Expand Down
6 changes: 3 additions & 3 deletions dev-dependencies.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import {
assert,
assertEquals,
assertStrictEq
} from 'https://deno.land/std@v0.56.0/testing/asserts.ts';
assertStrictEquals
} from 'https://deno.land/std@v0.61.0/testing/asserts.ts';

export {
assert,
assertEquals,
assertStrictEq
assertStrictEquals as assertStrictEq
};
2 changes: 1 addition & 1 deletion example/simple-server/dev-dependencies.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals, assertStrictEq } from 'https://deno.land/std@v0.56.0/testing/asserts.ts';
import { assertEquals, assertStrictEq } from 'https://deno.land/std@v0.61.0/testing/asserts.ts';

export {
assertEquals,
Expand Down
2 changes: 1 addition & 1 deletion lib/request.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export default class Request {
this.referrer = this.headers.get('referer') || '';
this.response = new Response();
this.server = options.server;
this.state = cookie.getCookies(this as any);
this.state = cookie.getCookies(this);
afaur marked this conversation as resolved.
Show resolved Hide resolved
this.url = new URL(this.raw.url, 'http://' + this.headers.get('host'));
}
get body() {
Expand Down
4 changes: 2 additions & 2 deletions lib/response.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ export default class Response {
state(name: cookie.Cookie): this;
state(name: string, value: string | CookieOptions): this;
state(name: string | cookie.Cookie, value?: string | CookieOptions) {
cookie.setCookie(this as object, {
cookie.setCookie(this, {
httpOnly : true,
sameSite : 'Strict',
secure : true,
Expand All @@ -95,7 +95,7 @@ export default class Response {
return this.header('Content-Type', mediaType);
}
unstate(name: string) {
cookie.delCookie(this as object, name);
cookie.deleteCookie(this, name);
return this;
}
}