remult 0.14.16 → 0.14.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -72,6 +72,8 @@ class middleware {
72
72
  if (m) {
73
73
  let h = m.get(req.method.toLowerCase());
74
74
  if (h) {
75
+ if (!req.params)
76
+ req.params = {};
75
77
  req.params.id = path.substring(idPosition + 1);
76
78
  h(req, res, next);
77
79
  return;
@@ -3,7 +3,7 @@ import axios from 'axios';
3
3
  import { HttpProviderBridgeToRestDataProviderHttpProvider, Remult } from '../context';
4
4
  import { Entity, Fields } from '../remult3';
5
5
  import { Action, BackendMethod } from '../server-action';
6
- Remult.apiBaseUrl = 'http://localhost:3001/api';
6
+ Remult.apiBaseUrl = 'http://localhost:8000/api';
7
7
  const path = Remult.apiBaseUrl + '/tasks';
8
8
  fit("works", async () => {
9
9
  const repo = await create3Tasks();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "remult",
3
- "version": "0.14.16",
3
+ "version": "0.14.17",
4
4
  "description": "A CRUD framework for full-stack TypeScript",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
@@ -76,6 +76,8 @@ var middleware = /** @class */ (function () {
76
76
  if (m) {
77
77
  var h = m.get(req.method.toLowerCase());
78
78
  if (h) {
79
+ if (!req.params)
80
+ req.params = {};
79
81
  req.params.id = path.substring(idPosition + 1);
80
82
  h(req, res, next);
81
83
  return;
@@ -6,7 +6,7 @@ var axios_1 = require("axios");
6
6
  var context_1 = require("../context");
7
7
  var remult3_1 = require("../remult3");
8
8
  var server_action_1 = require("../server-action");
9
- context_1.Remult.apiBaseUrl = 'http://localhost:3001/api';
9
+ context_1.Remult.apiBaseUrl = 'http://localhost:8000/api';
10
10
  var path = context_1.Remult.apiBaseUrl + '/tasks';
11
11
  fit("works", function () { return tslib_1.__awaiter(void 0, void 0, void 0, function () {
12
12
  var repo, tasks, _a;