From 764847164aecdad0764805181c6f3cc629aa4731 Mon Sep 17 00:00:00 2001 From: Max Semenik Date: Mon, 28 Oct 2019 00:07:17 -0700 Subject: [PATCH] Replace trigger_error('') magic with error_clear_last() Bug: T191247 Change-Id: I8bedd9c6df4648941c957d92fa8b0c8464f1d796 --- includes/engines/LuaStandalone/LuaStandaloneEngine.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/includes/engines/LuaStandalone/LuaStandaloneEngine.php b/includes/engines/LuaStandalone/LuaStandaloneEngine.php index 6bc6dd7a..90d58fe6 100644 --- a/includes/engines/LuaStandalone/LuaStandaloneEngine.php +++ b/includes/engines/LuaStandalone/LuaStandaloneEngine.php @@ -255,9 +255,7 @@ class Scribunto_LuaStandaloneInterpreter extends Scribunto_LuaInterpreter { // Clear the "last error", so if proc_open fails we can know any // warning was generated by that. - Wikimedia\suppressWarnings(); - trigger_error( '' ); - Wikimedia\restoreWarnings(); + error_clear_last(); $this->proc = proc_open( $cmd,