Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@pnp/adaljsclient

Package Overview
Dependencies
Maintainers
9
Versions
70
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pnp/adaljsclient - npm Package Compare versions

Comparing version 2.0.1-1 to 2.0.1-2

28

adalclient.js

@@ -1,5 +0,7 @@

import { __awaiter, __extends, __generator } from "tslib";
import { BearerTokenFetchClient, isUrlAbsolute, SPFxAdalClient, getADALResource } from "@pnp/common";
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var tslib_1 = require("tslib");
var common_1 = require("@pnp/common");
// @ts-ignore
import * as adal from "adal-angular/dist/adal.min.js";
var adal = require("adal-angular/dist/adal.min.js");
/**

@@ -9,3 +11,3 @@ * Azure AD Client for use in the browser

var AdalClient = /** @class */ (function (_super) {
__extends(AdalClient, _super);
tslib_1.__extends(AdalClient, _super);
/**

@@ -34,3 +36,3 @@ * Creates a new instance of AdalClient

AdalClient.fromSPFxContext = function (spfxContext) {
return new SPFxAdalClient(spfxContext);
return new common_1.SPFxAdalClient(spfxContext);
};

@@ -44,11 +46,11 @@ /**

AdalClient.prototype.fetch = function (url, options) {
return __awaiter(this, void 0, void 0, function () {
return tslib_1.__awaiter(this, void 0, void 0, function () {
var token;
return __generator(this, function (_a) {
return tslib_1.__generator(this, function (_a) {
switch (_a.label) {
case 0:
if (!isUrlAbsolute(url)) {
if (!common_1.isUrlAbsolute(url)) {
throw Error("You must supply absolute urls to AdalClient.fetch.");
}
return [4 /*yield*/, this.getToken(getADALResource(url))];
return [4 /*yield*/, this.getToken(common_1.getADALResource(url))];
case 1:

@@ -68,5 +70,5 @@ token = _a.sent();

AdalClient.prototype.getToken = function (resource) {
return __awaiter(this, void 0, void 0, function () {
return tslib_1.__awaiter(this, void 0, void 0, function () {
var token;
return __generator(this, function (_a) {
return tslib_1.__generator(this, function (_a) {
switch (_a.label) {

@@ -164,4 +166,4 @@ case 0: return [4 /*yield*/, this.ensureAuthContext()];

return AdalClient;
}(BearerTokenFetchClient));
export { AdalClient };
}(common_1.BearerTokenFetchClient));
exports.AdalClient = AdalClient;
//# sourceMappingURL=adalclient.js.map

@@ -1,2 +0,5 @@

export * from "./adalclient";
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var tslib_1 = require("tslib");
tslib_1.__exportStar(require("./adalclient"), exports);
//# sourceMappingURL=index.js.map
{
"name": "@pnp/adaljsclient",
"version": "2.0.1-1",
"version": "2.0.1-2",
"description": "pnp - provides an ADAL client for use with PnPjs",

@@ -10,3 +10,3 @@ "main": "./index.js",

"tslib": "1.10.0",
"@pnp/common": "2.0.1-1"
"@pnp/common": "2.0.1-2"
},

@@ -13,0 +13,0 @@ "devDependencies": {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc