mirror of
https://github.com/SkinnyMind/libgit2dart.git
synced 2025-05-05 04:39:07 -04:00
refactor!: use named arguments if there is more than one
This commit is contained in:
parent
ec80ad3dd4
commit
5f7fdf4bd3
66 changed files with 1920 additions and 1136 deletions
|
@ -7,13 +7,18 @@ import '../util.dart';
|
|||
/// Determine if an object can be found in the object database by an abbreviated object ID.
|
||||
///
|
||||
/// Throws a [LibGit2Error] if error occured.
|
||||
Pointer<git_oid> existsPrefix(
|
||||
Pointer<git_odb> db,
|
||||
Pointer<git_oid> shortOid,
|
||||
int len,
|
||||
) {
|
||||
Pointer<git_oid> existsPrefix({
|
||||
required Pointer<git_odb> odbPointer,
|
||||
required Pointer<git_oid> shortOidPointer,
|
||||
required int length,
|
||||
}) {
|
||||
final out = calloc<git_oid>();
|
||||
final error = libgit2.git_odb_exists_prefix(out, db, shortOid, len);
|
||||
final error = libgit2.git_odb_exists_prefix(
|
||||
out,
|
||||
odbPointer,
|
||||
shortOidPointer,
|
||||
length,
|
||||
);
|
||||
|
||||
if (error < 0) {
|
||||
throw LibGit2Error(libgit2.git_error_last());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue