fix(core): Fix the type for InstalledNodes.latestVersion (no-changelog) (#10782)
Some checks are pending
Test Master / install-and-build (push) Waiting to run
Test Master / Unit tests (18.x) (push) Blocked by required conditions
Test Master / Unit tests (20.x) (push) Blocked by required conditions
Test Master / Unit tests (22.4) (push) Blocked by required conditions
Test Master / Lint (push) Blocked by required conditions
Test Master / Notify Slack on failure (push) Blocked by required conditions
Benchmark Docker Image CI / build (push) Waiting to run

This commit is contained in:
कारतोफ्फेलस्क्रिप्ट™ 2024-09-12 11:14:03 +02:00 committed by GitHub
parent 8496adb94f
commit 7d6ec6544e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 5 additions and 5 deletions

View file

@ -10,7 +10,7 @@ export class InstalledNodes {
type: string; type: string;
@Column() @Column()
latestVersion: string; latestVersion: number;
@ManyToOne('InstalledPackages', 'installedNodes') @ManyToOne('InstalledPackages', 'installedNodes')
@JoinColumn({ name: 'package', referencedColumnName: 'packageName' }) @JoinColumn({ name: 'package', referencedColumnName: 'packageName' })

View file

@ -35,7 +35,7 @@ export class InstalledPackagesRepository extends Repository<InstalledPackages> {
const installedNode = this.installedNodesRepository.create({ const installedNode = this.installedNodesRepository.create({
name: nodeTypes[loadedNode.name].type.description.displayName, name: nodeTypes[loadedNode.name].type.description.displayName,
type: loadedNode.name, type: loadedNode.name,
latestVersion: loadedNode.version.toString(), latestVersion: loadedNode.version,
package: { packageName }, package: { packageName },
}); });

View file

@ -104,7 +104,7 @@ export const MOCK_PACKAGE: InstalledPackages[] = [
{ {
name: 'My Test Node', name: 'My Test Node',
type: 'myTestNode', type: 'myTestNode',
latestVersion: '1', latestVersion: 1,
} as InstalledNodes, } as InstalledNodes,
], ],
}, },

View file

@ -22,7 +22,7 @@ export const mockNode = (packageName: string) => {
return Container.get(InstalledNodesRepository).create({ return Container.get(InstalledNodesRepository).create({
name: nodeName, name: nodeName,
type: nodeName, type: nodeName,
latestVersion: COMMUNITY_NODE_VERSION.CURRENT.toString(), latestVersion: COMMUNITY_NODE_VERSION.CURRENT,
package: { packageName }, package: { packageName },
}); });
}; };

View file

@ -2447,7 +2447,7 @@ export type PublicInstalledPackage = {
export type PublicInstalledNode = { export type PublicInstalledNode = {
name: string; name: string;
type: string; type: string;
latestVersion: string; latestVersion: number;
package: PublicInstalledPackage; package: PublicInstalledPackage;
}; };