The plugin fails to append a material to a mesh, if the material has previously been appended to a different mesh. This happens because material variable is only set in the condition that the current mat_path is not present in materials dictionary yet.
This change also assigns the material variable when the condition is false, to the material previously saved in the materials dictionary under the same mat_path.
The plugin fails to append a material to a mesh, if the material has previously been appended to a different mesh. This happens because material variable is only set in the condition that the current mat_path is not present in materials dictionary yet.
This change also assigns the material variable when the condition is false, to the material previously saved in the materials dictionary under the same mat_path.