style: use conts for constructors

This commit is contained in:
Aleksey Kulikov 2021-09-23 10:48:23 +03:00
parent e0e16aea30
commit 7187d890d6
17 changed files with 39 additions and 69 deletions

View file

@ -7,9 +7,7 @@ import 'util.dart';
class Oid {
/// Initializes a new instance of [Oid] class from provided
/// pointer to Oid object in memory.
Oid(this._oidPointer) {
libgit2.git_libgit2_init();
}
Oid(this._oidPointer);
/// Initializes a new instance of [Oid] class by determining if an object can be found
/// in the ODB of [repository] with provided hexadecimal [sha] string that is 40 characters
@ -34,7 +32,6 @@ class Oid {
/// Initializes a new instance of [Oid] class from provided raw git_oid.
Oid.fromRaw(git_oid raw) {
libgit2.git_libgit2_init();
_oidPointer = bindings.fromRaw(raw.id);
}