@es-git/object-mixin
Advanced tools
Comparing version 0.0.1 to 0.0.5
@@ -19,4 +19,2 @@ import { Type, Mode } from '@es-git/core'; | ||
return encodeTag(object.body); | ||
case 'text': | ||
return encodeBlob(encoder.encode(object.body)); | ||
default: | ||
@@ -23,0 +21,0 @@ throw new Error(`Unknown object type`); |
@@ -28,6 +28,2 @@ import { Type, Mode, Constructor, IRawRepo } from '@es-git/core'; | ||
}; | ||
export declare type TextObject = { | ||
readonly type: 'text'; | ||
readonly body: string; | ||
}; | ||
export declare type TreeObject = { | ||
@@ -63,2 +59,2 @@ readonly type: Type.tree; | ||
export declare type Body = Uint8Array | TreeBody | CommitBody | TagBody; | ||
export declare type GitObject = TextObject | BlobObject | TreeObject | CommitObject | TagObject; | ||
export declare type GitObject = BlobObject | TreeObject | CommitObject | TagObject; |
@@ -58,4 +58,2 @@ 'use strict'; | ||
return encodeTag(object.body); | ||
case 'text': | ||
return encodeBlob(encoder.encode(object.body)); | ||
default: | ||
@@ -62,0 +60,0 @@ throw new Error('Unknown object type'); |
{ | ||
"name": "@es-git/object-mixin", | ||
"version": "0.0.1", | ||
"version": "0.0.5", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "main": "js/index.js", |
@@ -36,4 +36,2 @@ import { | ||
return encodeTag(object.body); | ||
case 'text': | ||
return encodeBlob(encoder.encode(object.body)); | ||
default: | ||
@@ -40,0 +38,0 @@ throw new Error(`Unknown object type`); |
@@ -57,7 +57,2 @@ import { Type, Mode, Constructor, IRawRepo } from '@es-git/core'; | ||
export type TextObject = { | ||
readonly type : 'text' | ||
readonly body : string | ||
} | ||
export type TreeObject = { | ||
@@ -99,2 +94,2 @@ readonly type : Type.tree | ||
export type Body = Uint8Array | TreeBody | CommitBody | TagBody; | ||
export type GitObject = TextObject | BlobObject | TreeObject | CommitObject | TagObject; | ||
export type GitObject = BlobObject | TreeObject | CommitObject | TagObject; |
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
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
105888
1312