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

azurlane

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

azurlane - npm Package Compare versions

Comparing version 1.0.0 to 1.1.0

9

lib/index.d.ts

@@ -103,2 +103,11 @@ /// <reference types="node" />

/**
* @since 1.1.0
*
* Get information about a ship by id
*
* @param {string} id The id of the ship
* @returns {Promise<IShip>}
*/
getShipById(id: string): Promise<IShip>;
/**
* @since 0.0.1

@@ -105,0 +114,0 @@ *

@@ -58,2 +58,24 @@ 'use strict';

/**
* @since 1.1.0
*
* Get information about a ship by id
*
* @param {string} id The id of the ship
* @returns {Promise<IShip>}
*/
async getShipById(id) {
try {
const response = await axios.get(`${this.baseUrl}/ship?id=${id}`, this._axiosOptions);
return response.data.ship;
}
catch (error) {
if (error.response && error.response.data) {
throw new ApiError(error.response.data);
}
else {
throw error;
}
}
}
/**
* @since 0.0.1

@@ -60,0 +82,0 @@ *

2

package.json
{
"name": "azurlane",
"version": "1.0.0",
"version": "1.1.0",
"description": "Api wrapper for the azur lane api",

@@ -5,0 +5,0 @@ "main": "lib/index",

@@ -54,2 +54,23 @@ import axios, { AxiosRequestConfig } from "axios";

/**
* @since 1.1.0
*
* Get information about a ship by id
*
* @param {string} id The id of the ship
* @returns {Promise<IShip>}
*/
public async getShipById(id: string): Promise<IShip> {
try {
const response = await axios.get<IShipResponse>(`${this.baseUrl}/ship?id=${id}`, this._axiosOptions);
return response.data.ship;
} catch (error) {
if (error.response && error.response.data) {
throw new ApiError(error.response.data);
} else {
throw error;
}
}
}
/**
* @since 0.0.1

@@ -56,0 +77,0 @@ *

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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