Fix recursion in MetadataHelper.GetMetadata

This commit is contained in:
ghorsington committed 2019-06-16 18:48:41 +03:00
1 parent 6c8109cc45
commit ec22e7fc59
1 file changed
+1 -1
+1 -1
View File
@@ -159,7 +159,7 @@ namespace BepInEx
/// </summary>
/// <param name="plugin">The plugin instance.</param>
/// <returns>The BepInPlugin metadata of the plugin instance.</returns>
public static BepInPlugin GetMetadata(object plugin) => GetMetadata(plugin.GetType());
public static BepInPlugin GetMetadata(object plugin) => GetMetadata(plugin as BaseUnityPlugin);
/// <summary>
/// Gets the specified attributes of a type, if they exist.