@@ -438,7 +438,7 @@ void CipherBase::Init(const char* cipher_type,
438438
439439void CipherBase::Init (const FunctionCallbackInfo<Value>& args) {
440440 CipherBase* cipher;
441- ASSIGN_OR_RETURN_UNWRAP (&cipher, args.Holder ());
441+ ASSIGN_OR_RETURN_UNWRAP (&cipher, args.This ());
442442 Environment* env = Environment::GetCurrent (args);
443443
444444 CHECK_GE (args.Length (), 3 );
@@ -510,7 +510,7 @@ void CipherBase::InitIv(const char* cipher_type,
510510
511511void CipherBase::InitIv (const FunctionCallbackInfo<Value>& args) {
512512 CipherBase* cipher;
513- ASSIGN_OR_RETURN_UNWRAP (&cipher, args.Holder ());
513+ ASSIGN_OR_RETURN_UNWRAP (&cipher, args.This ());
514514 Environment* env = cipher->env ();
515515
516516 CHECK_GE (args.Length (), 4 );
@@ -645,7 +645,7 @@ bool CipherBase::IsAuthenticatedMode() const {
645645void CipherBase::GetAuthTag (const FunctionCallbackInfo<Value>& args) {
646646 Environment* env = Environment::GetCurrent (args);
647647 CipherBase* cipher;
648- ASSIGN_OR_RETURN_UNWRAP (&cipher, args.Holder ());
648+ ASSIGN_OR_RETURN_UNWRAP (&cipher, args.This ());
649649
650650 // Only callable after Final and if encrypting.
651651 if (cipher->ctx_ ||
@@ -661,7 +661,7 @@ void CipherBase::GetAuthTag(const FunctionCallbackInfo<Value>& args) {
661661
662662void CipherBase::SetAuthTag (const FunctionCallbackInfo<Value>& args) {
663663 CipherBase* cipher;
664- ASSIGN_OR_RETURN_UNWRAP (&cipher, args.Holder ());
664+ ASSIGN_OR_RETURN_UNWRAP (&cipher, args.This ());
665665 Environment* env = Environment::GetCurrent (args);
666666
667667 if (!cipher->ctx_ ||
@@ -773,7 +773,7 @@ bool CipherBase::SetAAD(
773773
774774void CipherBase::SetAAD (const FunctionCallbackInfo<Value>& args) {
775775 CipherBase* cipher;
776- ASSIGN_OR_RETURN_UNWRAP (&cipher, args.Holder ());
776+ ASSIGN_OR_RETURN_UNWRAP (&cipher, args.This ());
777777 Environment* env = Environment::GetCurrent (args);
778778
779779 CHECK_EQ (args.Length (), 2 );
@@ -886,7 +886,7 @@ bool CipherBase::SetAutoPadding(bool auto_padding) {
886886
887887void CipherBase::SetAutoPadding (const FunctionCallbackInfo<Value>& args) {
888888 CipherBase* cipher;
889- ASSIGN_OR_RETURN_UNWRAP (&cipher, args.Holder ());
889+ ASSIGN_OR_RETURN_UNWRAP (&cipher, args.This ());
890890
891891 bool b = cipher->SetAutoPadding (args.Length () < 1 || args[0 ]->IsTrue ());
892892 args.GetReturnValue ().Set (b); // Possibly report invalid state failure
@@ -961,7 +961,7 @@ void CipherBase::Final(const FunctionCallbackInfo<Value>& args) {
961961 Environment* env = Environment::GetCurrent (args);
962962
963963 CipherBase* cipher;
964- ASSIGN_OR_RETURN_UNWRAP (&cipher, args.Holder ());
964+ ASSIGN_OR_RETURN_UNWRAP (&cipher, args.This ());
965965 if (cipher->ctx_ == nullptr )
966966 return THROW_ERR_CRYPTO_INVALID_STATE (env);
967967
0 commit comments